-
Notifications
You must be signed in to change notification settings - Fork 1
/
export-DNA-lib.xml
163 lines (149 loc) · 5.35 KB
/
export-DNA-lib.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project default="package.all" name="Generate and Package a Java .Blend Data Model">
<target name="init">
<property name="version" value="1.1.1"/>
<property name="blender.cfgdir" value="${user.home}/.config/blender"/>
<property name="blender.java.package" value="org.blender"/>
<property name="blender.java.package.dir" value="org.blender"/>
<property name="java.blend.docs" value="/home/homac/repos/git/github/homacs/JavaBlendDocs/resources/dnadoc"/>
<property name="web.downloads" value="${user.home}/tmp/public_html/projects/JavaBlend/downloads"/>
<property name="project.name" value="JavaBlend"/>
<property name="package.name" value="${project.name}-${version}-DNA-${blender.version}"/>
<property name="workdir" value="${java.io.tmpdir}/${package.name}"/>
<property name="srcdir" value="${workdir}/src"/>
<property name="bindir" value="${workdir}/bin"/>
<property name="jarfile" value="${web.downloads}/${package.name}.jar"/>
<property name="zipfile" value="${web.downloads}/${project.name}-src-${version}-DNA-${blender.version}.zip"/>
<property name="javadoczip" value="${web.downloads}/${project.name}-javadoc-${version}-DNA-${blender.version}.zip"/>
<delete failonerror="false" includeEmptyDirs="true">
<fileset dir="${workdir}"/>
<fileset file="${zipfile}"/>
<fileset file="${javadoczip}"/>
</delete>
<mkdir dir="${workdir}"/>
<mkdir dir="${srcdir}"/>
<mkdir dir="${bindir}"/>
</target>
<target name="generate" depends="init">
<echo message="generating source code"/>
<java classname="org.cakelab.blender.generator.ModelGenerator">
<arg value="-in"/><arg file="${input}"/>
<arg value="-out"/><arg file="${srcdir}"/>
<arg value="-p"/><arg value="${blender.java.package}"/>
<arg value="-c"/><arg file="${java.blend.docs}"/>
<arg value="-u"/><arg value="true"/>
<classpath>
<pathelement location="bin"/>
<pathelement location="../org.cakelab.json/bin"/>
<pathelement location="../org.cakelab.jdoxml/bin"/>
<fileset dir="lib">
<include name="**/*.jar"/>
</fileset>
</classpath>
</java>
<copy todir="${srcdir}">
<fileset dir="src" casesensitive="yes">
<include name="**/*"/>
</fileset>
</copy>
<copy todir="${srcdir}">
<fileset dir="../org.cakelab.json/src" casesensitive="yes">
<include name="**/*"/>
</fileset>
</copy>
<copy todir="${srcdir}">
<fileset dir="../org.cakelab.jdoxml/src" casesensitive="yes">
<include name="**/*"/>
</fileset>
</copy>
</target>
<target name="package.src" depends="generate">
<echo message="creating source code package"/>
<copy todir="${workdir}">
<fileset dir="." casesensitive="yes">
<include name="doc/**/*"/>
<include name="licenses/**/*"/>
<include name="export-DNA-lib.xml"/>
<include name="generate.sh"/>
</fileset>
</copy>
<zip destfile="${zipfile}" basedir="${java.io.tmpdir}">
<include name="${package.name}/**/*"/>
<exclude name="${package.name}/bin"/>
</zip>
</target>
<target name="package.javadoc" depends="package.bin">
<echo message="creating javadoc"/>
<mkdir dir="${workdir}/javadoc"/>
<javadoc
access="protected"
author="true"
classpath="${bindir}"
destdir="${workdir}/javadoc"
doctitle="Java .Blend for Blender ${blender.version}"
nodeprecated="false"
nodeprecatedlist="false"
noindex="false"
nonavbar="false"
notree="false"
overview="${workdir}/doc/spec.html"
packagenames="org.*"
source="1.8"
sourcepath="${srcdir}"
splitindex="true"
use="true"
version="true"
/>
<echo message="zip javadoc"/>
<zip destfile="${javadoczip}" basedir="${workdir}/javadoc">
</zip>
</target>
<target name="compile" depends="generate">
<echo message="compiling"/>
<javac srcdir="${srcdir}"
destdir="${bindir}"
classpath="${jarfile}"
debug="off"
includeAntRuntime="false"
compiler="modern"
/>
<echo message="copying resources"/>
<copy todir="${bindir}">
<fileset dir="${srcdir}" casesensitive="yes">
<include name="**/*"/>
<exclude name="**/*.java"/>
</fileset>
</copy>
</target>
<target name="package.bin" depends="compile">
<echo message="creating binary package"/>
<jar destfile="${jarfile}" basedir="${bindir}">
<include name="**/*"/>
</jar>
</target>
<target name="package" depends="package.bin,package.src,package.javadoc">
<echo message="done."/>
</target>
<target name="package.all">
<antcall target="package">
<param name="blender.version" value="2.79"/>
<param name="input" value="versions/2.79.0-2.70.6.blend"/>
</antcall>
<antcall target="package">
<param name="blender.version" value="2.78"/>
<param name="input" value="versions/2.78.0-2.70.6.blend"/>
</antcall>
<antcall target="package">
<param name="blender.version" value="2.76"/>
<param name="input" value="versions/2.76.0-2.70.5.blend"/>
</antcall>
<antcall target="package">
<param name="blender.version" value="2.72"/>
<param name="input" value="versions/2.72.2-2.70.5.blend"/>
</antcall>
<antcall target="package">
<param name="blender.version" value="2.69"/>
<param name="input" value="versions/2.69.0-2.62.0.blend"/>
</antcall>
</target>
</project>