Project

General

Profile

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 329 jones
      <property name="installdir" value="/opt/tomcat/webapps/xmltodb" />
19 254 jones
      <property name="destdir" value="./classes" />
20
      <property name="srcdir" value="./src" />
21 113 jones
      <property name="oracle_home"
22 329 jones
                value="/oracle01/app/oracle/product/8.1.6" />
23
      <property name="toolsdir"
24
                value="/usr/local/devtools" />
25 113 jones
      <property name="xmlp"
26 329 jones
                value="${toolsdir}/OracleXSU111/lib/xmlparserv2.jar" />
27 185 jones
      <property name="xmlp2"
28 329 jones
                value="${toolsdir}/xerces-1_1_3/xerces.jar" />
29 113 jones
      <property name="jdbc"
30
                value="${oracle_home}/jdbc/lib/classes111.zip" />
31
      <property name="jserv"
32
                value="/usr/lib/apache/ApacheJServ.jar" />
33
      <property name="jsdk"
34 329 jones
                value="${toolsdir}/jakarta-tomcat/lib/servlet.jar" />
35 213 jones
      <property name="srb"
36
                value="lib/srbrmi" />
37 113 jones
      <property name="cpath"
38 319 jones
                value="${xmlp2}:${xmlp}:${jdbc}:${jserv}:${jsdk}:${srb}"/>
39 254 jones
      <property name="package.home" value="edu/ucsb/nceas/metacat" />
40
      <mkdir dir="${destdir}" />
41 113 jones
   </target>
42
43 204 jones
   <target name="compile" depends="init">
44 254 jones
       <javac srcdir="${srcdir}"
45
              destdir="${destdir}"
46 257 jones
              classpath="${cpath}"
47
              excludes="**/*.sql" />
48 116 jones
       <copyfile src="lib/metacat.properties"
49 254 jones
                 dest="${destdir}/${package.home}/metacat.properties" />
50 306 berkley
       <copyfile src="lib/marine/marine.properties"
51 305 berkley
                 dest="${destdir}/${package.home}/marine/marine.properties" />
52 113 jones
   </target>
53
54 204 jones
   <target name="jar" depends="compile">
55 116 jones
       <delete file="lib/metacat.jar" />
56 254 jones
       <copydir src="lib/srbrmi" dest="${destdir}" />
57
       <jar jarfile="lib/metacat.jar" basedir="${destdir}" />
58 113 jones
   </target>
59
60 204 jones
   <target name="install" depends="jar">
61 329 jones
       <mkdir dir="${installdir}/WEB-INF/lib" />
62
       <copyfile src="lib/metacat.jar"
63
                 dest="${installdir}/WEB-INF/lib/metacat.jar" />
64
       <copyfile src="${xmlp2}"
65
                 dest="${installdir}/WEB-INF/lib/xerces.jar" />
66
       <copyfile src="${xmlp}"
67
                 dest="${installdir}/WEB-INF/lib/xmlparserv2.jar" />
68
       <copyfile src="${jdbc}"
69
                 dest="${installdir}/WEB-INF/lib/oracle-jdbc111.jar" />
70
       <copyfile src="lib/web.xml"
71
                 dest="${installdir}/WEB-INF/web.xml" />
72
       <copydir src="lib" dest="${installdir}"
73
                excludes="*.jar,*.properties,web.xml,**/srbrmi/*" />
74
       <copydir src="images" dest="${installdir}" />
75 204 jones
   </target>
76
77 113 jones
   <target name="clean" depends="init">
78 116 jones
       <delete file="lib/metacat.jar" />
79 254 jones
       <deltree dir="${destdir}" />
80 113 jones
   </target>
81
82
   <target name="jdoc" depends="init">
83
       <javadoc packagenames="edu.ucsb.nceas.metacat"
84
           sourcepath="src"
85
           destdir="docs"
86
           author="true"
87
           version="true"
88
           use="true"
89
           windowtitle="MetaCat API"
90
           doctitle="&lt;h1&gt;MetaCat Server&lt;/h1&gt;"
91
           bottom="&lt;i&gt;Copyright &#169; 2000 National Center for Ecological Analysis and Synthesis. All Rights Reserved.&lt;/i&gt;"
92
       />
93
   </target>
94
95
</project>