-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathbuild.xml
86 lines (73 loc) · 3.33 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
<?xml version="1.0"?>
<project name="master" default="distToDist">
<import file="01_conf/properties.xml"/>
<description>Master build file</description>
<!--+=========================================================================================+-->
<!--+ Targets for children +-->
<!--+ Not nice but easy to use and we keep all the targets from the master build +-->
<!--+=========================================================================================+-->
<target name="-delegate" description="Delegates target to children">
<fail unless="target">Wrong usage: $ant -Dtarget=<target_name></fail>
<ant dir="${projects.dir}/mystery/" target="${target}" inheritAll="false" />
<ant dir="${projects.dir}/bytecode/" target="${target}" inheritAll="false" />
<ant dir="${projects.dir}/mathparser/" target="${target}" inheritAll="false" />
<ant dir="${projects.dir}/encoding/" target="${target}" inheritAll="false"/>
<ant dir="${projects.dir}/visitor/" target="${target}" inheritAll="false" />
<ant dir="${projects.dir}/pjba/" target="${target}" inheritAll="false" />
<ant dir="${projects.dir}/logicalexp/" target="${target}" inheritAll="false" />
</target>
<target name="nop" description="Checks projects build">
<antcall target="-delegate">
<param name="target" value="nop"/>
</antcall>
</target>
<target name="clean" description="Removes directories: 03_dist & 04_build">
<antcall target="-delegate">
<param name="target" value="clean"/>
</antcall>
</target>
<target name="assemble" description="Assembles pjb files">
<antcall target="-delegate">
<param name="target" value="assemble"/>
</antcall>
</target>
<target name="compile" description="Compiles Main">
<antcall target="-delegate">
<param name="target" value="compile"/>
</antcall>
</target>
<target name="test" description="Executes Unit Tests">
<antcall target="-delegate">
<param name="target" value="test"/>
</antcall>
</target>
<target name="archive" description="Creates a JAR file">
<antcall target="-delegate">
<param name="target" value="archive"/>
</antcall>
</target>
<!--+=========================================================================================+-->
<!--+ Targets for master +-->
<!--+=========================================================================================+-->
<target name="clean-all" depends="clean-archives" description="Removes directory: 04_archives">
<antcall target="-delegate">
<param name="target" value="clean"/>
</antcall>
</target>
<target name="clean-archives" description="Removes directory: 04_archives">
<delete dir="${archives.dir}" />
</target>
<target name="-init-archives">
<mkdir dir="${archives.dir}" />
</target>
<target name="distToDist" depends="-init-archives" description="Copy all generated JARs to 04_archives">
<antcall target="-delegate">
<param name="target" value="archive"/>
</antcall>
<copy todir="${archives.dir}" flatten="true">
<fileset dir="${projects.dir}">
<include name="**/${dist.dir_str}/*.jar" />
</fileset>
</copy>
</target>
</project>