-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathbuild.xml
95 lines (84 loc) · 2.64 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
<?xml version="1.0" encoding="ISO-8859-1"?>
<project name="housefire" default="test" basedir=".">
<property name="project" value="housefire" />
<property name="build-dir" value="build" />
<property name="dist-dir" value="dist" />
<property name="doc-dir" value="javadoc" />
<property name="src-dir" value="src" />
<property name="cp" value=".;build;automaton/dist/automaton.jar" />
<property name="optimize" value="on" />
<property name="debug" value="off" />
<target name="all" depends="jar,doc" />
<target name="benchmark" depends="compile">
<java classname="HashBenchmark"
classpath="${cp}"
fork="yes">
</java>
</target>
<target name="compile">
<mkdir dir="${build-dir}" />
<javac srcdir="${src-dir}" destdir="${build-dir}" optimize="${optimize}"
debug="${debug}"
includeantruntime="false">
<classpath>
<pathelement path="${cp}" />
</classpath>
</javac>
</target>
<target name="optimize" depends="clean">
<mkdir dir="${build-dir}" />
<javac srcdir="${src-dir}" destdir="${build-dir}" optimize="${optimize}"
debug="${debug}"
includeantruntime="false">
<classpath>
<pathelement path="${cp}" />
</classpath>
</javac>
</target>
<target name="test" depends="compile">
<java classname="Driver"
fork="yes"
classpath="build;automaton/dist/automaton.jar">
<arg value="-server" />
</java>
</target>
<target name="zip" depends="jar">
<zip destfile="housefire.zip"
basedir="${dist-dir}"
update="true" />
</target>
<target name="jar" depends="compile">
<delete dir="${dist-dir}" />
<mkdir dir="${dist-dir}" />
<copy todir="${dist-dir}/doc">
<fileset dir="doc" />
</copy>
<copy todir="${dist-dir}/automaton/dist">
<fileset dir="automaton/dist" />
</copy>
<copy todir="${dist-dir}/images">
<fileset dir="images" />
</copy>
<jar jarfile="${dist-dir}/${project}.jar">
<fileset dir="${build-dir}" />
<manifest>
<attribute name="Class-Path" value="automaton/dist/automaton.jar" />
<attribute name="Main-Class" value="Driver" />
</manifest>
</jar>
</target>
<target name="clean">
<delete dir="${build-dir}" />
<delete dir="${doc-dir}" />
<delete dir="${dist-dir}" />
</target>
<target name="doc" depends="jar">
<mkdir dir="${doc-dir}" />
<javadoc sourcepath="${src-dir}"
destdir="${doc-dir}">
<doctitle><![CDATA[JHouseFire<br>API Specification]]></doctitle>
<bottom><![CDATA[<i> Copyright © 2012 u're mum. </i>]]></bottom>
<link href="http://goatsemarathon.com" />
</javadoc>
</target>
</project>