-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.xml
executable file
·71 lines (66 loc) · 2.85 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
<project name="wyrl" default="build">
<import file="config.xml"/>
<target name="compile-wyrl">
<javac debug="true" debuglevel="vars,lines,source" source="1.7" target="1.7" includeantruntime="true" classpath="${WYBS_JAR}">
<src path="src"/>
<include name="wyrl/util/WyrlAntTask.java"/>
</javac>
<taskdef name="wyrl" classname="wyrl.util.WyrlAntTask" classpath="src/:${WYBS_JAR}"/>
<wyrl srcdir="src/" debug="false" source="wyrl/core/Types.wyrl" output="wyrl/core/Types.java"/>
<javac debug="true" debuglevel="vars,lines,source" source="1.7" target="1.7" includeantruntime="true" classpath="${WYBS_JAR}">
<src path="src"/>
<include name="*/**"/>
<exclude name="*/**/package-info.java"/>
</javac>
</target>
<target name="build" depends="compile-wyrl">
<mkdir dir="tmp"/>
<manifest file="tmp/MANIFEST.MF">
<attribute name="Built-By" value="${user.name}"/>
<attribute name="Main-Class" value="wyrl.Main"/>
<attribute name="Implementation-Version" value="${version}"/>
<attribute name="Implementation-Title" value="wyrl-v${version}.jar"/>
</manifest>
<jar destfile="lib/wyrl-v${version}.jar" manifest="tmp/MANIFEST.MF">
<fileset dir="src" includes="*/**/*.class"/>
</jar>
<delete dir="tmp"/>
<echo message="============================================="/>
<echo message="BUILT: lib/${ant.project.name}-v${version}.jar"/>
<echo message="============================================="/>
</target>
<target name="distsrc">
<mkdir dir="wyrl-v${version}"/>
<copy todir="wyrl-v${version}">
<fileset dir=".">
<include name="LICENSE"/>
<include name="README"/>
<include name="build.xml"/>
<include name="config.xml"/>
<include name="*/**/*.java"/>
<include name="*/**/*.wyrl"/>
<include name="lib/*-v${version}.jar"/>
</fileset>
</copy>
<tar destfile="dist/wyrl-src-v${version}.tar" longfile="gnu">
<tarfileset dir="." includes="wyrl-v${version}/**/*"/>
<tarfileset dir="." filemode="755">
<include name="wyrl-v${version}/bin/*"/>
</tarfileset>
</tar>
<gzip destfile="dist/wyrl-src-v${version}.tgz" src="dist/wyrl-src-v${version}.tar"/>
<delete file="dist/wyrl-src-v${version}.tar"/>
<delete dir="wyrl-v${version}"/>
<echo message="============================================="/>
<echo message="BUILT: dist/wyrl-src-v${version}.tgz"/>
<echo message="============================================="/>
</target>
<target name="clean">
<delete includeEmptyDirs="true" failonerror="false">
<fileset dir="." includes="**/*.class,**/*.wyil,**/*.wyasm"/>
</delete>
<echo message="============================================="/>
<echo message="CLEANED: ${ant.project.name}"/>
<echo message="============================================="/>
</target>
</project>