-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.xml
228 lines (198 loc) · 6.34 KB
/
build.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
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
<?xml version="1.0" encoding="UTF-8"?>
<!-- <!DOCTYPE project PUBLIC "-//ANT//DTD project//EN" "project.dtd"> -->
<!--
$Author: reuter $
$Date: 2008-01-01 10:24:45 +0100 (Tue, 01 Jan 2008) $
$Id: build.xml 296 2008-01-01 09:24:45Z reuter $
-->
<project name="syngraph" default="all" basedir=".">
<!--
This is standard definition of all build commands that is
included by other build files.
-->
<!-- set DSTAMP, TSTAMP, and TODAY properties -->
<tstamp />
<!-- relative position in the file system -->
<property name="projectroot" value="."/>
<!-- standard structure of the module -->
<property name="srcdir" value="${projectroot}/src"/>
<property name="mediadir" value="${srcdir}/media"/>
<!-- the name of the project -->
<property name="projectname" value="syngraph"/>
<property name="appmain" value="org.soundpaint.syngraph.SynGraph"/>
<!-- project version -->
<!-- <loadfile property="version" srcFile="${projectroot}/VERSION"/> -->
<!-- FIXME: The value for property "version" should be taken from
file VERSION in the project root directory. -->
<property name="version" value="0.0.1"/>
<!--
<exec executable="${projectroot}/extract_version_id.sh"
outputproperty="version" os="Linux" />
-->
<!-- CLASSPATH definition -->
<path id="classpath">
<pathelement path="${classdir}"/>
</path>
<!-- standard structure of output files -->
<property name="builddir" value="${projectroot}/build"/>
<property name="outputdir" value="${builddir}/${ant.project.name}"/>
<property name="classdir" value="${outputdir}/class"/>
<property name="helpdocdir" value="${outputdir}/helpdoc"/>
<property name="webdocdir" value="${outputdir}/webdoc"/>
<property name="javadocdir" value="${outputdir}/javadoc"/>
<property name="webdir" value="${outputdir}/web"/>
<property name="libdir" value="${outputdir}/lib"/>
<property name="binjar" value="${libdir}/${ant.project.name}.jar"/>
<property name="javadoczip" value="${libdir}/${ant.project.name}_javadoc.zip"/>
<property name="webdoczip" value="${libdir}/${ant.project.name}_webdoc.zip"/>
<property name="java-sources" value="${srcdir}/java"/>
<property name="doc-sources" value="${srcdir}/doc"/>
<!-- build targets -->
<target name="bin" depends="syg">
<mkdir dir="${classdir}"/>
<javac target="1.5" source="1.5" debug="yes"
srcdir="${java-sources}" destdir="${classdir}"
deprecation="yes">
<compilerarg value="-Xlint:all"/>
<classpath refid="classpath"/>
</javac>
</target>
<target name="syg">
<mkdir dir="${outputdir}/media"/>
<zip destfile="${outputdir}/media/template.syg">
<zipfileset dir="${srcdir}/media" includes="MAP"/>
</zip>
</target>
<target name="bin.jar" depends="bin,helpdoc">
<mkdir dir="${libdir}"/>
<jar jarfile="${binjar}"
manifest="${srcdir}/META-INF/MANIFEST.MF"
update="false">
<fileset dir="${projectroot}" casesensitive="yes">
<include name="COPYING_??"/>
</fileset>
<fileset dir="${classdir}"/>
<fileset dir="${java-sources}">
<include name="**/*.properties"/>
</fileset>
<fileset dir="${outputdir}">
<include name="media/*.syg"/>
</fileset>
<fileset dir="${srcdir}">
<include name="media/*.png"/>
</fileset>
<fileset dir="${outputdir}">
<include name="helpdoc/**" />
</fileset>
<manifest>
<attribute name="Specification-Version"
value="${version}"/>
<attribute name="Implementation-Version"
value="${version} ${TODAY}"/>
</manifest>
</jar>
<!--
<signjar jar="${binjar}"
alias="syngraph"
storepass="syngraph_build"
keystore="${build_keystore}"/>
-->
</target>
<target name="helpdoc">
<!--
<copy todir="${helpdocdir}">
<fileset dir="${doc-sources}" defaultexcludes="yes">
<include name="**/*.html"/>
</fileset>
</copy>
-->
<xslt style="${doc-sources}/xhtml2html.xslt"
destdir="${helpdocdir}"
basedir="src/doc"
processor="trax"
includes="**/*.html">
<classpath refid="classpath"/>
</xslt>
<copy todir="${helpdocdir}">
<fileset dir="${doc-sources}" defaultexcludes="yes">
<include name="**/*.css"/>
<include name="images/**"/>
</fileset>
</copy>
</target>
<target name="webdoc">
<mkdir dir="${webdocdir}"/>
<copy todir="${webdocdir}">
<fileset dir="${doc-sources}" defaultexcludes="yes">
<include name="**/*.htaccess"/>
<include name="**/*.html"/>
<include name="**/*.css"/>
<include name="images/**"/>
</fileset>
</copy>
</target>
<target name="webdoc.zip" depends="webdoc">
<mkdir dir="${libdir}"/>
<zip destfile="${webdoczip}" basedir="${webdocdir}"/>
</target>
<target name="javadoc">
<mkdir dir="${javadocdir}"/>
<javadoc destdir="${javadocdir}"
author="true"
version="true"
use="true"
access="private"
windowtitle="SynGraph Java Documentation"
>
<fileset dir="${java-sources}" defaultexcludes="yes">
<include name="**/*.java"/>
</fileset>
<classpath refid="classpath"/>
<doctitle><![CDATA[<h1>SynGraph $version$</h1>]]></doctitle>
<bottom>
<![CDATA[<i>Copyright © 2006 by Jürgen Reuter.</i>]]>
</bottom>
</javadoc>
</target>
<target name="javadoc.zip" depends="javadoc">
<mkdir dir="${libdir}"/>
<zip destfile="${javadoczip}" basedir="${javadocdir}"/>
</target>
<target name="all" depends="bin.jar,webdoc.zip,javadoc.zip"/>
<target name="run" depends="bin.jar">
<java jar="${binjar}" fork="yes">
<!--
<arg value="example.syg"/>
-->
<assertions>
<enable />
</assertions>
<classpath refid="classpath"/>
</java>
</target>
<target name="tarball">
<tstamp prefix="tarstamp.">
<format property="TODAY" pattern="yyyy-MM-dd.HH-mm-ss" />
</tstamp>
<tar destfile="${projectroot}/../syngraph-${tarstamp.TODAY}.src.tar.bz2"
compression="bzip2">
<tarfileset dir="." prefix="syngraph-${tarstamp.TODAY}">
<exclude name="**/*~" />
<exclude name="build/**" />
</tarfileset>
</tar>
</target>
<target name="clean">
<delete dir="${outputdir}"/>
</target>
<target name="cleanall">
<delete dir="${antbuildrootdir}"/>
</target>
</project>
<!--
Local Variables:
coding:utf-8
mode:sgml
mode:nXML
End:
-->