1 |
113
|
jones
|
<?xml version="1.0"?>
|
2 |
|
|
<!--
|
3 |
|
|
* build.xml
|
4 |
|
|
*
|
5 |
|
|
* Authors: Matt Jones
|
6 |
|
|
* Copyright: 2000 Regents of the University of California and the
|
7 |
|
|
* National Center for Ecological Analysis and Synthesis
|
8 |
|
|
* For Details: http://www.nceas.ucsb.edu/
|
9 |
|
|
* File Info: '$Id$'
|
10 |
|
|
*
|
11 |
|
|
* Build file for the Ant cross-platform build system for metacat
|
12 |
|
|
* See http://jakarta.apache.org for details on Ant
|
13 |
|
|
*
|
14 |
303
|
jones
|
* usage: ant [compile|jar|install|jdoc]
|
15 |
113
|
jones
|
-->
|
16 |
329
|
jones
|
<project name="metacat" default="jar" basedir=".">
|
17 |
113
|
jones
|
<target name="init">
|
18 |
410
|
berkley
|
<property name="installdir" value="/opt/tomcat/webapps/metadata" />
|
19 |
348
|
jones
|
<property name="name" value="metacat"/>
|
20 |
|
|
<property name="Name" value="MetaCat"/>
|
21 |
378
|
jones
|
<property name="release" value="1.0a8"/>
|
22 |
412
|
berkley
|
<property name="servlet-path" value="/metadata/servlet/metacat"/>
|
23 |
410
|
berkley
|
<property name="html-path" value="/metadata"/>
|
24 |
|
|
<property name="image-path" value="/img/metadata" />
|
25 |
412
|
berkley
|
<property name="user" value="metadata"/>
|
26 |
410
|
berkley
|
<property name="password" value="your-pw-here"/>
|
27 |
348
|
jones
|
|
28 |
|
|
<filter token="release" value="${release}"/>
|
29 |
|
|
<filter token="servlet-path" value="${servlet-path}"/>
|
30 |
359
|
bojilova
|
<filter token="html-path" value="${html-path}"/>
|
31 |
362
|
jones
|
<filter token="user" value="${user}"/>
|
32 |
|
|
<filter token="password" value="${password}"/>
|
33 |
409
|
berkley
|
<filter token="image-path" value="${image-path}"/>
|
34 |
254
|
jones
|
<property name="srcdir" value="./src" />
|
35 |
348
|
jones
|
|
36 |
|
|
<property name="build.dir" value="./build"/>
|
37 |
|
|
<property name="build.src" value="${build.dir}/src"/>
|
38 |
|
|
<property name="build.dest" value="${build.dir}/classes"/>
|
39 |
|
|
<property name="build.docs" value="${build.dir}/docs/html"/>
|
40 |
|
|
<property name="build.samples" value="${build.dir}/samples"/>
|
41 |
|
|
<property name="build.tests" value="${build.dir}/tests"/>
|
42 |
|
|
<property name="build.data" value="${build.dir}/data"/>
|
43 |
|
|
<property name="build.javadocs" value="${build.dir}/docs/apiDocs"/>
|
44 |
409
|
berkley
|
<property name="build.img" value="/opt/httpd/html${image-path}"/>
|
45 |
348
|
jones
|
|
46 |
113
|
jones
|
<property name="oracle_home"
|
47 |
329
|
jones
|
value="/oracle01/app/oracle/product/8.1.6" />
|
48 |
|
|
<property name="toolsdir"
|
49 |
|
|
value="/usr/local/devtools" />
|
50 |
113
|
jones
|
<property name="xmlp"
|
51 |
329
|
jones
|
value="${toolsdir}/OracleXSU111/lib/xmlparserv2.jar" />
|
52 |
185
|
jones
|
<property name="xmlp2"
|
53 |
329
|
jones
|
value="${toolsdir}/xerces-1_1_3/xerces.jar" />
|
54 |
113
|
jones
|
<property name="jdbc"
|
55 |
|
|
value="${oracle_home}/jdbc/lib/classes111.zip" />
|
56 |
|
|
<property name="jserv"
|
57 |
|
|
value="/usr/lib/apache/ApacheJServ.jar" />
|
58 |
|
|
<property name="jsdk"
|
59 |
329
|
jones
|
value="${toolsdir}/jakarta-tomcat/lib/servlet.jar" />
|
60 |
213
|
jones
|
<property name="srb"
|
61 |
|
|
value="lib/srbrmi" />
|
62 |
113
|
jones
|
<property name="cpath"
|
63 |
319
|
jones
|
value="${xmlp2}:${xmlp}:${jdbc}:${jserv}:${jsdk}:${srb}"/>
|
64 |
254
|
jones
|
<property name="package.home" value="edu/ucsb/nceas/metacat" />
|
65 |
348
|
jones
|
|
66 |
113
|
jones
|
</target>
|
67 |
|
|
|
68 |
348
|
jones
|
<target name="prepare" depends="init">
|
69 |
|
|
<mkdir dir="${build.dir}"/>
|
70 |
|
|
<mkdir dir="${build.src}"/>
|
71 |
|
|
<mkdir dir="${build.dest}"/>
|
72 |
|
|
|
73 |
|
|
<copydir src="${srcdir}"
|
74 |
|
|
dest="${build.src}"
|
75 |
|
|
filtering="yes"
|
76 |
|
|
includes="edu/**, com/**"
|
77 |
|
|
excludes="**/CVS* **/.#* **/*.sql"/>
|
78 |
|
|
|
79 |
|
|
</target>
|
80 |
|
|
|
81 |
|
|
<target name="compile" depends="prepare">
|
82 |
|
|
<javac srcdir="${build.src}"
|
83 |
|
|
destdir="${build.dest}"
|
84 |
257
|
jones
|
classpath="${cpath}"
|
85 |
|
|
excludes="**/*.sql" />
|
86 |
116
|
jones
|
<copyfile src="lib/metacat.properties"
|
87 |
356
|
bojilova
|
dest="${build.dest}/${package.home}/metacat.properties"
|
88 |
|
|
filtering="yes" />
|
89 |
306
|
berkley
|
<copyfile src="lib/marine/marine.properties"
|
90 |
348
|
jones
|
dest="${build.dest}/${package.home}/marine/marine.properties"/>
|
91 |
113
|
jones
|
</target>
|
92 |
|
|
|
93 |
204
|
jones
|
<target name="jar" depends="compile">
|
94 |
353
|
jones
|
<delete file="${build.dir}/${name}.jar" />
|
95 |
348
|
jones
|
<copydir src="lib/srbrmi" dest="${build.dest}" />
|
96 |
353
|
jones
|
<jar jarfile="${build.dir}/${name}.jar" basedir="${build.dest}" />
|
97 |
113
|
jones
|
</target>
|
98 |
|
|
|
99 |
204
|
jones
|
<target name="install" depends="jar">
|
100 |
329
|
jones
|
<mkdir dir="${installdir}/WEB-INF/lib" />
|
101 |
353
|
jones
|
<copyfile src="${build.dir}/${name}.jar"
|
102 |
348
|
jones
|
dest="${installdir}/WEB-INF/lib/${name}.jar" />
|
103 |
329
|
jones
|
<copyfile src="${xmlp2}"
|
104 |
|
|
dest="${installdir}/WEB-INF/lib/xerces.jar" />
|
105 |
|
|
<copyfile src="${xmlp}"
|
106 |
|
|
dest="${installdir}/WEB-INF/lib/xmlparserv2.jar" />
|
107 |
|
|
<copyfile src="${jdbc}"
|
108 |
|
|
dest="${installdir}/WEB-INF/lib/oracle-jdbc111.jar" />
|
109 |
|
|
<copyfile src="lib/web.xml"
|
110 |
|
|
dest="${installdir}/WEB-INF/web.xml" />
|
111 |
409
|
berkley
|
<copydir src="lib"
|
112 |
410
|
berkley
|
dest="${build.img}"
|
113 |
|
|
filtering="yes"
|
114 |
|
|
includes="*.jpg,*.png,*.gif,**/marine/*.jpg, **/marine/*.png, **/marine/*.gif"/>
|
115 |
329
|
jones
|
<copydir src="lib" dest="${installdir}"
|
116 |
348
|
jones
|
filtering="yes"
|
117 |
329
|
jones
|
excludes="*.jar,*.properties,web.xml,**/srbrmi/*" />
|
118 |
391
|
jones
|
<mkdir dir="${installdir}/dtd" />
|
119 |
|
|
<copydir src="../dtd" dest="${installdir}/dtd"
|
120 |
|
|
filtering="yes"
|
121 |
|
|
includes="*.dtd" />
|
122 |
329
|
jones
|
<copydir src="images" dest="${installdir}" />
|
123 |
204
|
jones
|
</target>
|
124 |
|
|
|
125 |
113
|
jones
|
<target name="clean" depends="init">
|
126 |
348
|
jones
|
<deltree dir="${build.dir}" />
|
127 |
113
|
jones
|
</target>
|
128 |
|
|
|
129 |
|
|
<target name="jdoc" depends="init">
|
130 |
|
|
<javadoc packagenames="edu.ucsb.nceas.metacat"
|
131 |
|
|
sourcepath="src"
|
132 |
|
|
destdir="docs"
|
133 |
|
|
author="true"
|
134 |
|
|
version="true"
|
135 |
|
|
use="true"
|
136 |
348
|
jones
|
windowtitle="${Name} API"
|
137 |
|
|
doctitle="<h1>${Name}</h1>"
|
138 |
113
|
jones
|
bottom="<i>Copyright © 2000 National Center for Ecological Analysis and Synthesis. All Rights Reserved.</i>"
|
139 |
|
|
/>
|
140 |
|
|
</target>
|
141 |
|
|
|
142 |
|
|
</project>
|