-
Notifications
You must be signed in to change notification settings - Fork 2
/
build.xml
109 lines (86 loc) · 4 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
<project name="eSalsa-Tools" default="build" basedir=".">
<property name="version" value="1.2" />
<property name="prefix" value="esalsa-tools-${version}" />
<property name="jar" value="${prefix}.jar" />
<property name="zip" value="${prefix}.zip" />
<property name="src-zip" value="${prefix}-src.zip" />
<property name="srcdir" value="./src" />
<property name="builddir" value="./build" />
<property name="distdir" value="./dist" />
<property name="javadoc" value="${distdir}/docs/javadoc" />
<property name="build.sysclasspath" value="ignore"/>
<target name="prepare">
<mkdir dir="${distdir}" />
<mkdir dir="${distdir}/lib" />
<mkdir dir="${distdir}/docs" />
<mkdir dir="${distdir}/scripts"/>
<mkdir dir="${distdir}/notices"/>
<copy todir="${distdir}/lib">
<fileset dir="./lib" />
</copy>
<copy todir="${distdir}/scripts">
<fileset dir="./scripts"/>
</copy>
<chmod dir="${distdir}/scripts" perm="755"
includes="*.sh"/>
<copy todir="${distdir}/notices">
<fileset dir="./notices"/>
</copy>
<copy file="./docs/usersguide.pdf" todir="${distdir}/docs"/>
<copy file="README" todir="${distdir}"/>
<copy file="INSTALL" todir="${distdir}"/>
<copy file="HISTORY" todir="${distdir}"/>
<copy file="LICENSE" todir="${distdir}"/>
<copy file="NOTICE" todir="${distdir}"/>
</target>
<path id="default.classpath">
<fileset dir="lib">
<include name="*.jar" />
</fileset>
</path>
<!-- Compile eSalsa loadbalancer -->
<target name="compile" depends="prepare">
<delete dir="${builddir}" />
<mkdir dir="${builddir}" />
<javac destdir="${builddir}" srcdir="${srcdir}" target="1.6" source="1.6" debug="true" includes="nl/esciencecenter/esalsa/**/*.java" classpathref="default.classpath" />
<jar jarfile="${distdir}/lib/${jar}" basedir="${builddir}" includes="**">
<manifest>
<attribute name="Built-By" value="${user.name}" />
</manifest>
</jar>
</target>
<target name="javadoc" description="Create javadocs" depends="prepare">
<!-- Create the javadoc -->
<mkdir dir="${javadoc}" />
<mkdir dir="${javadoc}/esalsa" />
<javadoc destdir="${javadoc}/esalsa" access="public" sourcepath="src" windowtitle="eSalsa Tools Documentation" packagenames="nl.esciencecenter.esalsa.*" doctitle="eSalsa Tools ${version} Documentation" bottom="eSalsa Tools ${version}" classpathref="default.classpath">
<link href="http://download.oracle.com/javase/1.6.0/docs/api/" />
</javadoc>
</target>
<target name="build" depends="clean,prepare,compile,javadoc">
</target>
<target name="bin.zip" depends="build">
<delete failonerror="false" file="${zip}" />
<zip destfile="${zip}">
<zipfileset dir="./dist" prefix="${prefix}" includes="notices/**,docs/**,lib/**,README,INSTALL,LICENSE,HISTORY,NOTICE" />
<zipfileset dir="./dist" prefix="${prefix}" filemode="755" includes="scripts/**" />
</zip>
</target>
<target name="src.zip">
<delete failonerror="false" file="${src-zip}" />
<zip destfile="${src-zip}">
<zipfileset dir="." prefix="${prefix}" includes="src/**,lib/**,notices/**,docs/**,README,INSTALL,LICENSE,HISTORY,NOTICE,build.xml" />
<zipfileset dir="." prefix="${prefix}" filemode="755" includes="scripts/**" />
</zip>
</target>
<!-- remove all generated code -->
<target name="clean" description="Removes the ${distdir} directory">
<delete failonerror="false" dir="${builddir}" />
<delete failonerror="false" dir="${distdir}" />
</target>
<target name="distclean" depends="clean">
<delete failonerror="false" dir="./bin" />
<delete failonerror="false" file="${zip}" />
<delete failonerror="false" file="${src-zip}" />
</target>
</project>