1 |
bobby |
1.1 |
<?xml version="1.0"?> |
2 |
|
|
|
3 |
|
|
<project name="commonJava" default="default" basedir="."> |
4 |
|
|
|
5 |
|
|
|
6 |
|
|
<property file="${user.home}/build.properties" /> |
7 |
|
|
|
8 |
|
|
<property name="Name" value="CommonJava Library"/> |
9 |
|
|
<property name="name" value="${project_name}"/> |
10 |
|
|
<property name="version" value="1.0"/> |
11 |
|
|
<property name="javaAPI" value="http://java.sun.com/j2se/1.4/docs/api/" /> |
12 |
|
|
<property name="home" value="${basedir}"/> |
13 |
|
|
<property name="src.dir" value="${home}/src"/> |
14 |
|
|
<property name="etc.dir" value="${home}/etc"/> |
15 |
|
|
<property name="tests.dir" value="${home}/src/test"/> |
16 |
|
|
<property name="classes.dir" value="${home}/classes"/> |
17 |
|
|
<property name="lib.dir" value="${home}/lib"/> |
18 |
|
|
<property name="docs.dir" value="${home}/docs"/> |
19 |
|
|
<property name="sample.dir" value="${home}/samples"/> |
20 |
|
|
<property name="dist.dir" value="${home}/dist/${name}"/> |
21 |
|
|
<!-- <property name="build.compiler" value="jikes"/>--> |
22 |
|
|
|
23 |
|
|
|
24 |
|
|
|
25 |
|
|
<path id="project.classpath"> |
26 |
|
|
<pathelement path="${classpath}" /> |
27 |
|
|
</path> |
28 |
|
|
|
29 |
|
|
<property name="copyright" |
30 |
|
|
value="Copyright © 2000-2002 Robert Sandell BTH. All Rights Reserved."/> |
31 |
|
|
|
32 |
|
|
<!-- |
33 |
|
|
|
34 |
|
|
Default |
35 |
|
|
|
36 |
|
|
--> |
37 |
|
|
<target name="default" depends="compile,jar-lib"/> |
38 |
|
|
|
39 |
|
|
<!-- |
40 |
|
|
|
41 |
|
|
All |
42 |
|
|
|
43 |
|
|
--> |
44 |
|
|
<target name="all" depends="clean,compile,doc"/> |
45 |
|
|
|
46 |
|
|
|
47 |
|
|
<!-- |
48 |
|
|
|
49 |
|
|
Rebuild |
50 |
|
|
|
51 |
|
|
--> |
52 |
|
|
<target name="rebuild" depends="clean,compile"/> |
53 |
|
|
|
54 |
|
|
|
55 |
|
|
<!-- |
56 |
|
|
Dristribution |
57 |
|
|
--> |
58 |
|
|
<target name="dist" depends="jar-lib, doc" /> |
59 |
|
|
|
60 |
|
|
<!-- |
61 |
|
|
|
62 |
|
|
Prepare |
63 |
|
|
|
64 |
|
|
--> |
65 |
|
|
<target name="prepare" depends="clean"> |
66 |
|
|
|
67 |
|
|
<tstamp/> |
68 |
|
|
|
69 |
|
|
<mkdir dir="${classes.dir}"/> |
70 |
|
|
<mkdir dir="${lib.dir}"/> |
71 |
|
|
<mkdir dir="${docs.dir}/api"/> |
72 |
|
|
<mkdir dir="${sample.dir}"/> |
73 |
|
|
</target> |
74 |
|
|
|
75 |
|
|
<!-- |
76 |
|
|
|
77 |
|
|
Compile Java Source |
78 |
|
|
|
79 |
|
|
--> |
80 |
|
|
<target name="compile" depends="prepare"> |
81 |
|
|
|
82 |
|
|
<javac fork="yes" srcdir="${src.dir}" destdir="${classes.dir}" classpath="${classpath}" debug="off" optimize="on"/> |
83 |
|
|
|
84 |
|
|
</target> |
85 |
|
|
|
86 |
|
|
<target name="jar-lib" depends="clean, compile, manifest"> |
87 |
|
|
<mkdir dir="${lib.dir}/develop"/> |
88 |
|
|
|
89 |
|
|
<!-- Put everything in ${build} into the MyProject-${DSTAMP}.jar file --> |
90 |
|
|
<!-- <copy file="${src.dir}/buildnumber.txt" todir="${classes.dir}"/>--> |
91 |
|
|
|
92 |
|
|
<!-- Put everything in ${build} into the MyProject-${DSTAMP}.jar file --> |
93 |
|
|
<jar jarfile="${lib.dir}/develop/${project_name}.jar" |
94 |
|
|
basedir="${classes.dir}" manifest="${lib.dir}/MANIFEST.MF" |
95 |
|
|
|
96 |
|
|
/> |
97 |
|
|
</target> |
98 |
|
|
|
99 |
|
|
|
100 |
|
|
<target name="manifest"> |
101 |
|
|
<mkdir dir="${lib.dir}"/> |
102 |
|
|
<manifest file="${lib.dir}/MANIFEST.MF"> |
103 |
|
|
<attribute name="Built-By" value="${user.name}"/> |
104 |
|
|
<!-- <attribute name="NAME" value="Bundle-Name entry" />--> |
105 |
|
|
<attribute name="Description" value="CommonJava Library" /> |
106 |
|
|
<attribute name="Vendor" value="Robert Sandell" /> |
107 |
|
|
<attribute name="Version" value="${version} ${TODAY}" /> |
108 |
|
|
|
109 |
|
|
<attribute name="Contact" value="Robert.Sandell@bth.se" /> |
110 |
|
|
<attribute name="Contact alt" value="pt00rsa@student.bth.se" /> |
111 |
|
|
<!-- <attribute name="BUNDLE-CLASSPATH" value="" />--> |
112 |
|
|
<!-- <attribute name="BUNDLE-CATEGORY" value="" />--> |
113 |
|
|
<!-- <attribute name="BUNDLE-CONFIG" value="" />--> |
114 |
|
|
<!-- <attribute name="PUBLIC-SRC-DIRS" value="" />--> |
115 |
|
|
<!-- <attribute name="IMPL-SRC-DIRS" value="" />--> |
116 |
|
|
<!-- <attribute name="DATA-DIRS" value="" />--> |
117 |
|
|
</manifest> |
118 |
|
|
</target> |
119 |
|
|
|
120 |
|
|
|
121 |
|
|
<!-- |
122 |
|
|
|
123 |
|
|
JavaDoc |
124 |
|
|
|
125 |
|
|
--> |
126 |
|
|
<target name="doc" depends="prepare"> |
127 |
|
|
|
128 |
|
|
<javadoc |
129 |
|
|
packagenames="commonJava.*" |
130 |
|
|
sourcepath="${src.dir}" |
131 |
|
|
destdir="${docs.dir}/api" |
132 |
|
|
author="true" |
133 |
|
|
version="true" |
134 |
|
|
windowtitle="${Name} API" |
135 |
|
|
doctitle="${Name} API" |
136 |
|
|
bottom="${copyright}"> |
137 |
|
|
</javadoc> |
138 |
|
|
|
139 |
|
|
</target> |
140 |
|
|
|
141 |
|
|
|
142 |
|
|
|
143 |
|
|
<!-- |
144 |
|
|
|
145 |
|
|
Clean |
146 |
|
|
|
147 |
|
|
--> |
148 |
|
|
<target name="clean"> |
149 |
|
|
|
150 |
|
|
|
151 |
|
|
<!-- <delete dir="${classes.dir}"/>--> |
152 |
|
|
<delete dir="${docs.dir}/api"/> |
153 |
|
|
<delete file="${lib.dir}/${project_name}.jar"/> |
154 |
|
|
<delete dir="${home}/dist"/> |
155 |
|
|
|
156 |
|
|
</target> |
157 |
|
|
|
158 |
|
|
</project> |