1
|
<?xml version="1.0"?>
|
2
|
<!--
|
3
|
* '$RCSfile$'
|
4
|
* Authors: Matt Jones, Chad Berkley, Jivka Bojilova
|
5
|
* Copyright: 2000 Regents of the University of California and the
|
6
|
* National Center for Ecological Analysis and Synthesis
|
7
|
* For Details: http://www.nceas.ucsb.edu/
|
8
|
*
|
9
|
* '$Author: tao $'
|
10
|
* '$Date: 2003-07-02 16:00:25 -0700 (Wed, 02 Jul 2003) $'
|
11
|
* '$Revision: 1722 $'
|
12
|
*
|
13
|
* Build file for the Ant cross-platform build system for metacat
|
14
|
* See http://jakarta.apache.org for details on Ant
|
15
|
*
|
16
|
* usage: ant [compile|jar|install|jdoc]
|
17
|
*
|
18
|
* This program is free software; you can redistribute it and/or modify
|
19
|
* it under the terms of the GNU General Public License as published by
|
20
|
* the Free Software Foundation; either version 2 of the License, or
|
21
|
* (at your option) any later version.
|
22
|
*
|
23
|
* This program is distributed in the hope that it will be useful,
|
24
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
25
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
26
|
* GNU General Public License for more details.
|
27
|
*
|
28
|
* You should have received a copy of the GNU General Public License
|
29
|
* along with this program; if not, write to the Free Software
|
30
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
31
|
-->
|
32
|
<project name="metacat" default="jar" basedir=".">
|
33
|
|
34
|
<target name="oracle">
|
35
|
<!-- Customize these properties if you are using oracle -->
|
36
|
<property name="jdbc-connect"
|
37
|
value="jdbc:oracle:thin:@dev.nceas.ucsb.edu:1521:exp"/>
|
38
|
<property name="dbDriver" value="oracle.jdbc.driver.OracleDriver"/>
|
39
|
<property name="dbAdapter" value="edu.ucsb.nceas.dbadapter.OracleAdapter"/>
|
40
|
<property name="oracle_home" value="/oracle01/app/oracle/product/8.1.6" />
|
41
|
<property name="jdbc" value="${oracle_home}/jdbc/lib/classes111.zip" />
|
42
|
</target>
|
43
|
|
44
|
<target name="postgresql">
|
45
|
<!-- Customize these properties if you are using postgres -->
|
46
|
<property name="jdbc-connect"
|
47
|
value="jdbc:postgresql://localhost/exp"/>
|
48
|
<property name="dbDriver" value="org.postgresql.Driver"/>
|
49
|
<property name="dbAdapter"
|
50
|
value="edu.ucsb.nceas.dbadapter.PostgresqlAdapter"/>
|
51
|
<property name="jdbc" value="lib/jdbc7.1-1.2.jar" />
|
52
|
</target>
|
53
|
|
54
|
<target name="config" depends="postgresql">
|
55
|
<!-- Change the 'depends' attribute above to 'postgresql' to install
|
56
|
metacat with postgres instead of oracle -->
|
57
|
|
58
|
<!-- Customize these properties for your system -->
|
59
|
<property name="tomcat" value="/usr/local/devtools/jakarta-tomcat" />
|
60
|
<property name="webapps" value="/usr/local/devtools/jakarta-tomcat/webapps" />
|
61
|
<property name="context" value="tao" />
|
62
|
<property name="user" value="tao"/>
|
63
|
<property name="password" value=""/>
|
64
|
|
65
|
<property name="server" value="pine.nceas.ucsb.edu:8080"/>
|
66
|
<property name="systemidserver" value="http://pine.nceas.ucsb.edu:8080" />
|
67
|
<property name="datafilepath" value="/usr/local/devtools/jakarta-tomcat/data/tao/data" />
|
68
|
<property name="inlinedatafilepath" value="/usr/local/devtools/jakarta-tomcat/data/tao/inlinedata" />
|
69
|
<property name="debuglevel" value="40" />
|
70
|
|
71
|
<property name="forcereplicationwaitingtime" value="30000"/>
|
72
|
<property name="cvsroot"
|
73
|
value=":ext:tao@cvs.ecoinformatics.org:/cvs" />
|
74
|
<property name="web-base-url"
|
75
|
value="http://knb.ecoinformatics.org"/>
|
76
|
<property name="default-style" value="knb" />
|
77
|
<property name="morphosourcedir" value="../morpho" />
|
78
|
<property name="defaultcontenttype" value="application/octet-stream" />
|
79
|
|
80
|
<!-- Make sure these paths match the location of the jar files
|
81
|
on your system, the defaults should usually work -->
|
82
|
<property name="jsdk"
|
83
|
value="${tomcat}/lib/common/servlet.jar" />
|
84
|
<property name="xmlp"
|
85
|
value="lib/xercesImpl.jar" />
|
86
|
<property name="srb"
|
87
|
value="lib/srbrmi" />
|
88
|
<property name="cos"
|
89
|
value="lib/cos.jar" />
|
90
|
<property name="morpho"
|
91
|
value="lib/morpho.jar" />
|
92
|
<property name="xalan"
|
93
|
value="lib/xalan/xalan.jar" />
|
94
|
<property name="apis"
|
95
|
value="lib/xalan/xml-apis.jar" />
|
96
|
<property name="httpclient"
|
97
|
value="${morphosourcedir}/lib/httpclient.jar" />
|
98
|
<property name="itis"
|
99
|
value="${morphosourcedir}/lib/itislib.jar" />
|
100
|
<property name="emlparser"
|
101
|
value="lib/eml.jar" />
|
102
|
<property name="configxml"
|
103
|
value="lib/configxml.jar" />
|
104
|
<property name="itislib"
|
105
|
value="lib/itislib.jar" />
|
106
|
<property name="emlparser"
|
107
|
value="lib/eml.jar" />
|
108
|
</target>
|
109
|
|
110
|
<target name="init" depends="config">
|
111
|
<!-- It is less likely you'll need to make any changes from here down,
|
112
|
but customization is possible -->
|
113
|
<property name="installdir" value="${webapps}/${context}" />
|
114
|
<property name="name" value="metacat"/>
|
115
|
<property name="Name" value="MetaCat"/>
|
116
|
<property name="debugprefix" value="${Name}:"/>
|
117
|
<property name="release" value="1.2.1"/>
|
118
|
<property name="replication-path"
|
119
|
value="/${context}/servlet/replication"/>
|
120
|
<property name="servlet-path" value="/${context}/servlet/metacat"/>
|
121
|
<property name="html-path" value="/${context}"/>
|
122
|
<property name="image-path" value="/${context}" />
|
123
|
<property name="style-path" value="/${context}/style"/>
|
124
|
<property name="replication-log" value="/tmp/metacatreplication.log"/>
|
125
|
<property name="replicationerrorlog" value="/tmp/metacatreplication.err"/>
|
126
|
<property name="config-dir" value="${installdir}" />
|
127
|
<property name="eml-module" value="eml" />
|
128
|
<property name="eml-version" value="2.0.0beta6" />
|
129
|
<property name="eml-tag" value="RELEASE_EML_2_0_0_BETA_6_REV1" />
|
130
|
<property name="eml2-tag" value="STMML_SCHEMA_UPDATE" />
|
131
|
<property name="eml2namespace" value="eml://ecoinformatics.org/eml-2.0.0" />
|
132
|
<property name="stmmlnamespace" value="http://www.xml-cml.org/schema/stmml" />
|
133
|
|
134
|
<property name="cpath"
|
135
|
value="${xmlp}:${xalan}:${apis}:${jdbc}:${jsdk}:${srb}:${cos}:${morpho}:${emlparser}"/>
|
136
|
|
137
|
<filter token="docrooturl" value="./" />
|
138
|
<filter token="jdbc-connect" value="${jdbc-connect}"/>
|
139
|
<filter token="dbDriver" value="${dbDriver}"/>
|
140
|
<filter token="dbAdapter" value="${dbAdapter}"/>
|
141
|
<filter token="install-dir" value="${installdir}"/>
|
142
|
<filter token="server" value="${server}"/>
|
143
|
<filter token="systemidserver" value="${systemidserver}"/>
|
144
|
<filter token="replication-log" value="${replication-log}"/>
|
145
|
<filter token="replicationerrorlog" value="${replicationerrorlog}"/>
|
146
|
<filter token="release" value="${release}"/>
|
147
|
<filter token="servlet-path" value="${servlet-path}"/>
|
148
|
<filter token="html-path" value="${html-path}"/>
|
149
|
<filter token="user" value="${user}"/>
|
150
|
<filter token="password" value="${password}"/>
|
151
|
<filter token="image-path" value="${image-path}"/>
|
152
|
<filter token="style-path" value="${style-path}"/>
|
153
|
<filter token="web-base-url" value="${web-base-url}"/>
|
154
|
<filter token="replication-path" value="${replication-path}"/>
|
155
|
<filter token="config-dir" value="${config-dir}"/>
|
156
|
<filter token="default-style" value="${default-style}"/>
|
157
|
<filter token="eml-version" value="${eml-version}"/>
|
158
|
<filter token="eml2namespace" value="${eml2namespace}"/>
|
159
|
<filter token="stmmlnamespace" value="${stmmlnamespace}"/>
|
160
|
<filter token="context" value="${context}"/>
|
161
|
<filter token="forcereplicationwaitingtime" value="${forcereplicationwaitingtime}" />
|
162
|
<filter token="debuglevel" value="${debuglevel}" />
|
163
|
<filter token="datafilepath" value="${datafilepath}" />
|
164
|
<filter token="inlinedatafilepath" value="${inlinedatafilepath}" />
|
165
|
<filter token="defaultcontenttype" value="${defaultcontenttype}" />
|
166
|
<filter token="debugprefix" value="${debugprefix}"/>
|
167
|
|
168
|
<property name="srcdir" value="./src" />
|
169
|
<property name="junittestsdir" value="./test/edu/ucsb/nceas/metacattest" />
|
170
|
<property name="junitnettestsdir" value="./test/edu/ucsb/nceas/metacatnettest" />
|
171
|
<property name="build.dir" value="./build"/>
|
172
|
<property name="build.src" value="${build.dir}/src"/>
|
173
|
<property name="build.dest" value="${build.dir}/classes"/>
|
174
|
<property name="build.docs" value="${build.dir}/docs"/>
|
175
|
<property name="build.samples" value="${build.dir}/samples"/>
|
176
|
<property name="build.tests" value="${build.dir}/tests"/>
|
177
|
<property name="build.metacattest" value="${build.tests}/metacattest"/>
|
178
|
<property name="build.metacatnettest" value="${build.tests}/metacatnettest"/>
|
179
|
<property name="build.data" value="${build.dir}/data"/>
|
180
|
<property name="build.javadocs" value="${build.dir}/docs/api"/>
|
181
|
<property name="build.img" value="${installdir}"/>
|
182
|
|
183
|
<property name="dist.dir" value="dist"/>
|
184
|
<property name="ver.dir" value="${dist.dir}/${name}-${release}"/>
|
185
|
<property name="ver.src" value="${ver.dir}/src"/>
|
186
|
|
187
|
<property name="package.home" value="edu/ucsb/nceas/metacat" />
|
188
|
</target>
|
189
|
|
190
|
<target name="prepare" depends="init">
|
191
|
<mkdir dir="${build.dir}"/>
|
192
|
<mkdir dir="${build.src}"/>
|
193
|
<mkdir dir="${build.dest}"/>
|
194
|
<mkdir dir="${build.javadocs}"/>
|
195
|
|
196
|
<copy todir="${build.src}" filtering="yes">
|
197
|
<fileset dir="${srcdir}">
|
198
|
<include name="edu/**"/>
|
199
|
<include name="com/**"/>
|
200
|
<include name="**/*.sql"/>
|
201
|
<exclude name="**/CVS*"/>
|
202
|
<exclude name="**/.#*"/>
|
203
|
<exclude name="edu/ucsb/nceas/metacat/harvesterClient/*.*"/>
|
204
|
</fileset>
|
205
|
</copy>
|
206
|
</target>
|
207
|
|
208
|
<target name="compile" depends="prepare">
|
209
|
<javac srcdir="${build.src}"
|
210
|
destdir="${build.dest}"
|
211
|
classpath="${cpath}"
|
212
|
excludes="**/*.sql" />
|
213
|
<copy file="lib/metacat.properties"
|
214
|
tofile="${build.dest}/${package.home}/metacat.properties"
|
215
|
filtering="yes" />
|
216
|
<copy file="lib/srbProps.properties"
|
217
|
tofile="${build.dest}/${package.home}/srbProps.properties"/>
|
218
|
</target>
|
219
|
|
220
|
<target name="jar" depends="compile">
|
221
|
<delete file="${build.dir}/${name}.jar" />
|
222
|
<copy todir="${build.dest}">
|
223
|
<fileset dir="lib/srbrmi"/>
|
224
|
</copy>
|
225
|
<jar jarfile="${build.dir}/${name}.jar" basedir="${build.dest}"
|
226
|
excludes="**/protocols/" />
|
227
|
</target>
|
228
|
|
229
|
<target name="protocol" depends="compile">
|
230
|
<delete file="${build.dir}/protocol.jar" />
|
231
|
<jar jarfile="${build.dir}/protocol.jar" basedir="${build.dest}"
|
232
|
includes="**/protocols/" />
|
233
|
</target>
|
234
|
|
235
|
<target name="getdtdschema" depends="prepare">
|
236
|
<echo>Enter CVS password: </echo>
|
237
|
<cvs cvsRoot="${cvsroot}"
|
238
|
package="${eml-module}"
|
239
|
tag="${eml-tag}"
|
240
|
dest="${build.src}" />
|
241
|
<mkdir dir="lib/dtd" />
|
242
|
<copy todir="lib/dtd" filtering="yes">
|
243
|
<fileset dir="${build.src}/${eml-module}">
|
244
|
<include name="*.dtd"/>
|
245
|
</fileset>
|
246
|
<mapper type="glob" from="eml-*.dtd" to="eml-*-${eml-version}.dtd" />
|
247
|
</copy>
|
248
|
<echo>Enter CVS password: </echo>
|
249
|
<cvs cvsRoot="${cvsroot}"
|
250
|
package="${eml-module}"
|
251
|
tag="${eml2-tag}"
|
252
|
dest="${build.src}" />
|
253
|
<mkdir dir="lib/schema" />
|
254
|
<copy todir="lib/schema" filtering="yes">
|
255
|
<fileset dir="${build.src}/${eml-module}">
|
256
|
<include name="*.xsd"/>
|
257
|
</fileset>
|
258
|
</copy>
|
259
|
<copy todir="lib/style">
|
260
|
<fileset dir="${build.src}/${eml-module}/style">
|
261
|
<include name="*.xsl"/>
|
262
|
</fileset>
|
263
|
</copy>
|
264
|
</target>
|
265
|
|
266
|
<target name="getdtd" depends="prepare">
|
267
|
<echo>Enter CVS password: </echo>
|
268
|
<cvs cvsRoot="${cvsroot}"
|
269
|
package="${eml-module}"
|
270
|
tag="${eml-tag}"
|
271
|
dest="${build.src}" />
|
272
|
<mkdir dir="lib/dtd" />
|
273
|
<copy todir="lib/dtd" filtering="yes">
|
274
|
<fileset dir="${build.src}/${eml-module}">
|
275
|
<include name="*.dtd"/>
|
276
|
</fileset>
|
277
|
<mapper type="glob" from="eml-*.dtd" to="eml-*-${eml-version}.dtd" />
|
278
|
</copy>
|
279
|
</target>
|
280
|
|
281
|
<target name="getschema" depends="prepare">
|
282
|
<echo>Enter CVS password: </echo>
|
283
|
<cvs cvsRoot="${cvsroot}"
|
284
|
package="${eml-module}"
|
285
|
tag="${eml2-tag}"
|
286
|
dest="${build.src}" />
|
287
|
<mkdir dir="lib/schema" />
|
288
|
<copy todir="lib/schema" filtering="yes">
|
289
|
<fileset dir="${build.src}/${eml-module}">
|
290
|
<include name="*.xsd"/>
|
291
|
</fileset>
|
292
|
</copy>
|
293
|
<copy todir="lib/style">
|
294
|
<fileset dir="${build.src}/${eml-module}/style">
|
295
|
<include name="*.xsl"/>
|
296
|
</fileset>
|
297
|
</copy>
|
298
|
</target>
|
299
|
|
300
|
<target name="dtdschemasql" depends="prepare">
|
301
|
<echo/>
|
302
|
<echo>Registering the DTDs with the new Metacat instance...</echo>
|
303
|
<sql driver="${dbDriver}"
|
304
|
classpath="${jdbc}"
|
305
|
url="${jdbc-connect}"
|
306
|
userid="${user}"
|
307
|
password="${password}"
|
308
|
src="${build.src}/loaddtdschema.sql" />
|
309
|
</target>
|
310
|
|
311
|
<target name="schemasql" depends="prepare">
|
312
|
<echo/>
|
313
|
<echo>Registering the DTDs with the new Metacat instance...</echo>
|
314
|
<sql driver="${dbDriver}"
|
315
|
classpath="${jdbc}"
|
316
|
url="${jdbc-connect}"
|
317
|
userid="${user}"
|
318
|
password="${password}"
|
319
|
src="${build.src}/loadschema.sql" />
|
320
|
</target>
|
321
|
|
322
|
<target name="install" depends="jar">
|
323
|
<mkdir dir="${datafilepath}" />
|
324
|
<mkdir dir="${inlinedatafilepath}" />
|
325
|
<chmod dir="${datafilepath}" perm="ug+w" />
|
326
|
<mkdir dir="${installdir}/WEB-INF/lib" />
|
327
|
<copy file="${build.dir}/${name}.jar"
|
328
|
tofile="${installdir}/WEB-INF/lib/${name}.jar" />
|
329
|
<copy file="${xmlp}"
|
330
|
tofile="${installdir}/WEB-INF/lib/xercesImpl.jar" />
|
331
|
<copy file="${xalan}"
|
332
|
tofile="${installdir}/WEB-INF/lib/xalan.jar" />
|
333
|
<copy file="${apis}"
|
334
|
tofile="${installdir}/WEB-INF/lib/xml-apis.jar" />
|
335
|
<copy file="${jdbc}"
|
336
|
tofile="${installdir}/WEB-INF/lib/jdbc.jar" />
|
337
|
<copy file="${cos}"
|
338
|
tofile="${installdir}/WEB-INF/lib/cos.jar" />
|
339
|
<copy file="${morpho}"
|
340
|
tofile="${installdir}/WEB-INF/lib/morpho.jar" />
|
341
|
<copy file="${emlparser}"
|
342
|
tofile="${installdir}/WEB-INF/lib/eml.jar" />
|
343
|
<copy file="${configxml}"
|
344
|
tofile="${installdir}/WEB-INF/lib/configxml.jar" />
|
345
|
<copy file="${itislib}"
|
346
|
tofile="${installdir}/WEB-INF/lib/itislib.jar" />
|
347
|
<copy file="lib/web.xml"
|
348
|
tofile="${installdir}/WEB-INF/web.xml" />
|
349
|
<copy todir="${build.img}" filtering="no">
|
350
|
<fileset dir="lib">
|
351
|
<include name="**/*.jpg"/>
|
352
|
<include name="**/*.png"/>
|
353
|
<include name="**/*.gif"/>
|
354
|
</fileset>
|
355
|
</copy>
|
356
|
<copy todir="${installdir}" filtering="yes">
|
357
|
<fileset dir="lib">
|
358
|
<exclude name="*.jar"/>
|
359
|
<exclude name="*.properties"/>
|
360
|
<exclude name="web.xml"/>
|
361
|
<exclude name="**/srbrmi*"/>
|
362
|
<exclude name="**/*.jpg"/>
|
363
|
<exclude name="**/*.png"/>
|
364
|
<exclude name="**/*.gif"/>
|
365
|
</fileset>
|
366
|
</copy>
|
367
|
<echo>
|
368
|
***********************************************************
|
369
|
Remember to register the default DTDs by running the
|
370
|
"${build.src}/loaddtd.sql script". This is most easily
|
371
|
done by using the "ant dtdsql" which will run it for you.
|
372
|
***********************************************************
|
373
|
</echo>
|
374
|
</target>
|
375
|
|
376
|
<target name="test" depends="install">
|
377
|
<!-- copy and compile the tests into a jar file -->
|
378
|
<mkdir dir="${build.metacattest}"/>
|
379
|
<javac srcdir="${junittestsdir}"
|
380
|
destdir="${build.metacattest}"
|
381
|
classpath="${cpath}:${build.dir}/${name}.jar"
|
382
|
debug="on"
|
383
|
includes="**/*.java" />
|
384
|
|
385
|
<jar jarfile="${build.dir}/${name}-junittests.jar"
|
386
|
basedir="${build.metacattest}"
|
387
|
includes="**/*.class" />
|
388
|
|
389
|
<!-- use the ant "junit" task to run JUnit tests. -->
|
390
|
<junit printsummary="yes" haltonfailure="no" fork="no"
|
391
|
haltonerror="no">
|
392
|
<classpath>
|
393
|
<pathelement path="${cpath}:${build.dir}/${name}.jar:${build.dir}/${name}-junittests.jar" />
|
394
|
</classpath>
|
395
|
|
396
|
<formatter type="plain" />
|
397
|
|
398
|
<batchtest fork="yes" todir="${build.dir}">
|
399
|
<fileset dir="${build.metacattest}">
|
400
|
<include name="**/*.class" />
|
401
|
</fileset>
|
402
|
</batchtest>
|
403
|
</junit>
|
404
|
</target>
|
405
|
|
406
|
<target name="runonetest" depends="install">
|
407
|
<!-- copy and compile the tests into a jar file -->
|
408
|
<!--<property name="testtorun" value="SubTreeTest"/> -->
|
409
|
<echo>testtorun: ${testtorun}</echo>
|
410
|
<mkdir dir="${build.metacattest}"/>
|
411
|
<javac srcdir="${junittestsdir}"
|
412
|
destdir="${build.metacattest}"
|
413
|
classpath="${cpath}:${build.dir}/${name}.jar"
|
414
|
includes="**/*.java" />
|
415
|
|
416
|
<jar jarfile="${build.dir}/${name}-junittests.jar"
|
417
|
basedir="${build.metacattest}"
|
418
|
includes="**/*.class" />
|
419
|
|
420
|
<!-- use the ant "junit" task to run JUnit tests. -->
|
421
|
<junit printsummary="yes" haltonfailure="no" fork="no"
|
422
|
haltonerror="no">
|
423
|
<classpath>
|
424
|
<pathelement path="${cpath}:${build.dir}/${name}.jar:${build.dir}/${name}-junittests.jar" />
|
425
|
</classpath>
|
426
|
|
427
|
<formatter type="plain" />
|
428
|
|
429
|
<batchtest fork="yes" todir="${build.dir}">
|
430
|
<fileset dir="${build.metacattest}">
|
431
|
|
432
|
<include name="**/${testtorun}.class" />
|
433
|
</fileset>
|
434
|
</batchtest>
|
435
|
</junit>
|
436
|
</target>
|
437
|
|
438
|
<target name="gethttpclient" depends="prepare">
|
439
|
<!--mkdir dir="${morphosourcedir}" -->
|
440
|
<cvs cvsRoot="${cvsroot}"
|
441
|
package="morpho"
|
442
|
dest="." />
|
443
|
<ant dir="${morphosourcedir}" inheritAll="false" target="jar" />
|
444
|
</target>
|
445
|
|
446
|
<!-- run this target, we need to check out a another morpho souce dir was checked out. -->
|
447
|
<target name="nettest" depends="install">
|
448
|
<echo>***********************************
|
449
|
Please run ant gethttpclient first!
|
450
|
***********************************
|
451
|
</echo>
|
452
|
<!-- copy and compile the tests into a jar file -->
|
453
|
<mkdir dir="${build.metacatnettest}"/>
|
454
|
<javac srcdir="${junitnettestsdir}"
|
455
|
destdir="${build.metacatnettest}"
|
456
|
classpath="${cpath}:${build.dir}/${name}.jar:${httpclient}"
|
457
|
includes="**/*.java" />
|
458
|
|
459
|
<jar jarfile="${build.dir}/${name}-junitnettests.jar"
|
460
|
basedir="${build.metacatnettest}"
|
461
|
includes="**/*.class" />
|
462
|
|
463
|
<!-- use the ant "junit" task to run JUnit tests. -->
|
464
|
<junit printsummary="yes" haltonfailure="no" fork="yes"
|
465
|
haltonerror="no">
|
466
|
<jvmarg value="-Djava.protocol.handler.pkgs=HTTPClient" />
|
467
|
<classpath>
|
468
|
<pathelement path="${cpath}:${build.dir}/${name}.jar:${httpclient}:${build.dir}/${name}-junitnettests.jar:${itis}" />
|
469
|
</classpath>
|
470
|
|
471
|
<formatter type="plain" />
|
472
|
|
473
|
<batchtest fork="yes" todir="${build.dir}">
|
474
|
<fileset dir="${build.metacatnettest}">
|
475
|
<include name="**/*.class" />
|
476
|
</fileset>
|
477
|
</batchtest>
|
478
|
</junit>
|
479
|
</target>
|
480
|
|
481
|
<target name="servletclean" depends="clean">
|
482
|
<delete dir="${installdir}" />
|
483
|
</target>
|
484
|
|
485
|
|
486
|
<target name="clean" depends="init">
|
487
|
<delete dir="${build.dir}" />
|
488
|
</target>
|
489
|
|
490
|
<target name="jdoc" depends="prepare">
|
491
|
<javadoc packagenames="edu.ucsb.nceas.*"
|
492
|
sourcepath="${build.src}"
|
493
|
destdir="${build.javadocs}"
|
494
|
author="true"
|
495
|
version="true"
|
496
|
use="true"
|
497
|
windowtitle="${Name} API"
|
498
|
doctitle="<h1>${Name}</h1>"
|
499
|
bottom="<i>Copyright © 2000 National Center for Ecological Analysis and Synthesis. All Rights Reserved.</i>"
|
500
|
/>
|
501
|
</target>
|
502
|
|
503
|
<target name="dist" depends="jar,protocol,jdoc,getdtd">
|
504
|
<mkdir dir="${dist.dir}"/>
|
505
|
<delete dir="${ver.dir}" />
|
506
|
<mkdir dir="${ver.dir}"/>
|
507
|
<copy todir="${ver.dir}">
|
508
|
<fileset dir="."
|
509
|
excludes="**/CVS* **/.#* **/src* **/test* **/build* **/docs* ${dist.dir}"/>
|
510
|
</copy>
|
511
|
<copy todir="${ver.dir}" file="build.xml"/>
|
512
|
<copy todir="${ver.dir}/lib" file="${build.dir}/metacat.jar"/>
|
513
|
<copy todir="${ver.dir}/lib" file="${build.dir}/protocol.jar"/>
|
514
|
|
515
|
<copy todir="${ver.dir}/docs" filtering="yes">
|
516
|
<fileset dir="docs" excludes="**/*gif **/*jpg **/*png" />
|
517
|
</copy>
|
518
|
<copy todir="${ver.dir}/docs" filtering="no">
|
519
|
<fileset dir="docs" includes="**/*gif **/*jpg **/*png" />
|
520
|
</copy>
|
521
|
<copy todir="${ver.dir}/docs/dev">
|
522
|
<fileset dir="${build.dir}/docs"/>
|
523
|
</copy>
|
524
|
<copy todir="${ver.dir}/src">
|
525
|
<fileset dir="${build.dir}/src"/>
|
526
|
</copy>
|
527
|
|
528
|
<delete dir="./${ver.dir}/${build.dir}"/>
|
529
|
<delete dir="./${ver.dir}/dist"/>
|
530
|
<delete file="./${name}-${release}.zip"/>
|
531
|
<zip zipfile="./${name}-${release}.zip" basedir="${dist.dir}" excludes="${name}-${release}/src/**, ${name}-${release}/build/src/**"/>
|
532
|
<delete file="./${name}-${release}.tar.gz" />
|
533
|
<tar tarfile="./${name}-${release}.tar" basedir="${dist.dir}" excludes="${name}-${release}/src/**, ${name}-${release}/build/src/**"/>
|
534
|
<gzip zipfile="./${name}-${release}.tar.gz"
|
535
|
src="./${name}-${release}.tar"/>
|
536
|
<delete file="./${name}-${release}.tar" />
|
537
|
</target>
|
538
|
|
539
|
<target name="distsrc" depends="dist">
|
540
|
<mkdir dir="${ver.src}"/>
|
541
|
<copy todir="${ver.src}">
|
542
|
<fileset dir="./src"/>
|
543
|
</copy>
|
544
|
|
545
|
<delete file="./${name}-src-${release}.zip"/>
|
546
|
<zip zipfile="./${name}-src-${release}.zip" basedir="${dist.dir}"/>
|
547
|
<delete file="./${name}-src-${release}.tar.gz" />
|
548
|
<tar tarfile="./${name}-src-${release}.tar" basedir="${dist.dir}"/>
|
549
|
<gzip zipfile="./${name}-src-${release}.tar.gz"
|
550
|
src="./${name}-src-${release}.tar"/>
|
551
|
<delete file="./${name}-src-${release}.tar" />
|
552
|
<delete dir="${dist.dir}"/>
|
553
|
</target>
|
554
|
|
555
|
<target name="stylesheettest">
|
556
|
<xslt in="${input}" out="eml.html" style="lib/style/eml2/eml-2.0.0.xsl">
|
557
|
<param name="displaymodule" expression="${displaymodule}"/>
|
558
|
<param name="docid" expression="${input}"/>
|
559
|
<param name="entitytype" expression="${entitytype}"/>
|
560
|
<param name="entityindex" expression="${entityindex}"/>
|
561
|
<outputproperty name="method" value="html"/>
|
562
|
<outputproperty name="standalone" value="yes"/>
|
563
|
<outputproperty name="encoding" value="iso8859_1"/>
|
564
|
<outputproperty name="indent" value="yes"/>
|
565
|
</xslt>
|
566
|
</target>
|
567
|
|
568
|
</project>
|