Newer
Older
<project name="LightRPCApplication" default="build-all" basedir=".">
<property name="src.dir" value="src"/>
<property name="build.dir" value="build"/>
<property name="jar.dir" value="dist"/>
<property name="test.reports" value="reports"/>
<property name="test.src" value="test"/>
<!-- MAIN JOBS -->
<target name="build-all" depends="clean,jar,test" description="Compiles and packages the Common Jar">
</target>
<target name="clean" description="Removes artifacts from previous builds">
<delete dir="${build.dir}" includeemptydirs="true" />
<delete dir="${jar.dir}" includeemptydirs="true" />
<delete dir="${reports.dir}" includeemptydirs="true" />
</target>
<target name="jar" depends="compile">
<mkdir dir="${jar.dir}"/>
<attribute name="Main-Class" value="lightrpc.LightRPCMainStarter"/>
<attribute name="Class-Path" value="."/>
</manifest>
<fileset dir="${build.dir}"/>
<fileset dir="." includes="*LICENSE*" />
<zipfileset excludes="META-INF/*" src="lib/explorviz-monitoring.jar"/>
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
</jar>
</target>
<target name="compile">
<mkdir dir="${build.dir}"/>
<javac srcdir="${src.dir}" destdir="${build.dir}" classpathref="classpath" includeantruntime="false" debug="true" />
</target>
<path id="classpath">
<fileset dir=".">
<include name="lib/*.jar"/>
</fileset>
</path>
<!-- TEST JOBS -->
<target name="test" depends="compile-tests" description="JUnit-Tests">
<mkdir dir="${test.reports}" />
<junit printsummary="yes" fork="yes" haltonfailure="no">
<classpath>
<path refid="testclasspath"/>
</classpath>
<formatter type="xml" />
<batchtest todir="${test.reports}">
<fileset dir="${test.src}">
<include name="**/*Test.java" />
</fileset>
</batchtest>
</junit>
</target>
<target name="compile-tests" depends="compile">
<mkdir dir="${build.dir}"/>
<javac srcdir="${test.src}" destdir="${build.dir}" includeantruntime="false" debug="true">
<classpath>
<path refid="testclasspath"/>
</classpath>
</javac>
</target>
<path id="testclasspath">
<pathelement path="${build.dir}" />
<fileset dir="lib" includes="*.jar" />
</path>
</project>