-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.xml
112 lines (95 loc) · 4.89 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
110
111
112
<?xml version="1.0" encoding="ISO-8859-1"?>
<project name="ml-ant-http" default="dist" basedir=".">
<property name="ml-ant-http.lib.dir" location="lib"/>
<property name="ml-ant-http.src.dir" location="src"/>
<property name="ml-ant-http.java.src.dir" location="${ml-ant-http.src.dir}/java"/>
<property name="ml-ant-http.test.src.dir" location="${ml-ant-http.src.dir}/test"/>
<property name="ml-ant-http.build.dir" location="build"/>
<property name="ml-ant-http.build.classes.dir" location="${ml-ant-http.build.dir}/classes"/>
<property name="ml-ant-http.build.docs.dir" location="${ml-ant-http.build.dir}/docs"/>
<property name="ml-ant-http.dist.dir" location="dist"/>
<property name="ml-ant-http.resources.dir" location="resources"/>
<property name="ml-ant-http.license.dir" location="${ml-ant-http.resources.dir}/license"/>
<property name="ml-ant-http.license.file" value="license.txt"/>
<property name="ml-ant-http.dist.jar.name" value="ml-ant-http"/>
<property name="ml-ant-http.dist.jar.version" value="1.1.3"/>
<property name="ml-ant-http.dist.jar.dir" location="${ml-ant-http.dist.dir}/${ml-ant-http.dist.jar.name}-${ml-ant-http.dist.jar.version}"/>
<property name="ml-ant-http.dist.doc.zip" location="${ml-ant-http.dist.jar.dir}/${ml-ant-http.dist.jar.name}-${ml-ant-http.dist.jar.version}-api.zip"/>
<fileset id="ml-ant-http.compile.libs" dir="${ml-ant-http.lib.dir}">
<include name="apache-ant/apache-ant-1.8.2.jar"/>
<include name="junit/junit-4.8.2.jar"/>
</fileset>
<path id="ml-ant-http.compile.classpath">
<fileset refid="ml-ant-http.compile.libs"/>
</path>
<target name="clean">
<delete dir="${ml-ant-http.build.dir}"/>
<delete dir="${ml-ant-http.dist.dir}"/>
</target>
<target name="init">
<mkdir dir="${ml-ant-http.build.dir}"/>
<mkdir dir="${ml-ant-http.build.classes.dir}"/>
<mkdir dir="${ml-ant-http.build.docs.dir}"/>
<mkdir dir="${ml-ant-http.dist.dir}"/>
<mkdir dir="${ml-ant-http.dist.jar.dir}"/>
</target>
<target name="compile" depends="init">
<javac debug="yes" destdir="${ml-ant-http.build.classes.dir}" classpathref="ml-ant-http.compile.classpath" includeantruntime="false">
<src path="${ml-ant-http.java.src.dir}"/>
</javac>
</target>
<target name="jar" depends="compile">
<jar destfile="${ml-ant-http.dist.jar.dir}/${ml-ant-http.dist.jar.name}-${ml-ant-http.dist.jar.version}.jar" basedir="${ml-ant-http.build.classes.dir}">
<metainf dir="${ml-ant-http.license.dir}">
<include name="${ml-ant-http.license.file}"/>
</metainf>
<manifest>
<attribute name="Built-By" value="${user.name}"/>
</manifest>
</jar>
</target>
<target name="jar.src" depends="compile">
<jar destfile="${ml-ant-http.dist.jar.dir}/${ml-ant-http.dist.jar.name}-${ml-ant-http.dist.jar.version}-sources.jar" basedir="${ml-ant-http.java.src.dir}">
<metainf dir="${ml-ant-http.license.dir}">
<include name="${ml-ant-http.license.file}"/>
</metainf>
<manifest>
<attribute name="Built-By" value="${user.name}"/>
</manifest>
</jar>
</target>
<target name="javadoc" depends="init">
<javadoc destdir="${ml-ant-http.build.docs.dir}" author="true" version="true" use="true" windowtitle="missing link ant http task ${ml-ant-http.dist.jar.version}">
<packageset dir="${ml-ant-http.java.src.dir}" defaultexcludes="yes">
<include name="org/missinglink/**"/>
</packageset>
<doctitle><![CDATA[<h1>missing link ant http task ${ml-ant-http.dist.jar.version}</h1>]]></doctitle>
<bottom><![CDATA[<i>missing link ant http task ${ml-ant-http.dist.jar.version}</i>]]></bottom>
<tag name="todo" scope="all" description="To do:"/>
<link href="http://download.oracle.com/javase/6/docs/api/"/>
</javadoc>
<zip destfile="${ml-ant-http.dist.doc.zip}" basedir="${ml-ant-http.build.docs.dir}"/>
</target>
<target name="copy.dist.files" depends="compile">
<!-- license -->
<copy filtering="false" flatten="false" todir="${ml-ant-http.dist.jar.dir}">
<fileset dir="${ml-ant-http.license.dir}">
<include name="${ml-ant-http.license.file}"/>
</fileset>
</copy>
<filter token="ml-ant-http-version" value="${ml-ant-http.dist.jar.version}"/>
<copy filtering="true" flatten="true" todir="${ml-ant-http.dist.jar.dir}">
<fileset dir="${ml-ant-http.resources.dir}">
<include name="ant/build-sample.xml"/>
</fileset>
</copy>
<copy filtering="false" flatten="true" todir="${ml-ant-http.dist.jar.dir}">
<fileset dir="${ml-ant-http.resources.dir}">
<include name="doc/readme.pdf"/>
</fileset>
</copy>
</target>
<target name="dist" depends="compile,jar,jar.src,copy.dist.files,javadoc">
<zip destfile="${ml-ant-http.dist.dir}/${ml-ant-http.dist.jar.name}-${ml-ant-http.dist.jar.version}.zip" basedir="${ml-ant-http.dist.jar.dir}"/>
</target>
</project>