-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.xml
78 lines (64 loc) · 2.47 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
<project name="FajitaBoy Web" default="dist" basedir=".">
<description>
A simple build file for building FajitaBoy web-application.
</description>
<!-- set global properties for this build -->
<property name="src" location="src"/>
<property name="applet-src" location="src/fajitaboy"/>
<property name="web-src" location="src/web"/>
<property name="build" location="build"/>
<property name="dist-web" location="dist-web"/>
<property name="dist-jar" location="dist-jar"/>
<target name="init">
<!-- Create the time stamp -->
<tstamp/>
<!-- Create the build directory structure used by compile -->
</target>
<target name="compile" depends="init"
description="compile the source " >
<mkdir dir="${build}" />
<!-- Compile the java code from ${src} into ${build} -->
<!-- only compile the actual applet -->
<javac target="1.5"
srcdir="${src}"
destdir="${build}"
/>
<!-- Copy resources for the applet -->
<copy todir="${build}/fajitaboy/resources">
<fileset dir="${applet-src}/resources" />
</copy>
</target>
<target name="jar.check" depends="compile" >
<uptodate property="jarBuild.notRequired" targetfile="${dist-jar}/FajitaBoy.jar" >
<srcfiles dir="${build}" />
</uptodate>
</target>
<target name="fbjar" depends="compile,jar.check" unless="jarBuild.notRequired" >
<mkdir dir="${dist-jar}" />
<!-- Copy src/fajitaboy/images to build/fajitaboy/images -->
<copy todir="${build}/fajitaboy/resources">
<fileset dir="${applet-src}/resources" />
</copy>
<!-- <jar jarfile="${dist-web}/applet/FajitaBoy-${DSTAMP}.jar" basedir="${build}"/> -->
<jar jarfile="${dist-jar}/FajitaBoy.jar" basedir="${build}" />
<signjar jar="${dist-jar}/FajitaBoy.jar" alias="MyCert" keystore="cert/keystore" storepass="hahaha" />
</target>
<target name="dist" depends="compile,fbjar"
description="generate the distribution" >
<mkdir dir="${dist-web}"/>
<mkdir dir="${dist-web}/applet"/>
<copy file="${dist-jar}/FajitaBoy.jar" todir="${dist-web}/applet" />
<!-- <delete dir="${dist-jar}"/> -->
<!-- Copy src/www to dist-web -->
<copy todir="${dist-web}">
<fileset dir="${web-src}" />
</copy>
</target>
<target name="clean"
description="clean up" >
<!-- Delete the ${build} and ${dist} directory trees -->
<delete dir="${build}"/>
<delete dir="${dist-web}"/>
<delete dir="${dist-jar}"/>
</target>
</project>