1*ade3f226SDamjan Jovanovic<?xml version="1.0" encoding="UTF-8"?> 2*ade3f226SDamjan Jovanovic<!--*********************************************************** 3*ade3f226SDamjan Jovanovic * 4*ade3f226SDamjan Jovanovic * Licensed to the Apache Software Foundation (ASF) under one 5*ade3f226SDamjan Jovanovic * or more contributor license agreements. See the NOTICE file 6*ade3f226SDamjan Jovanovic * distributed with this work for additional information 7*ade3f226SDamjan Jovanovic * regarding copyright ownership. The ASF licenses this file 8*ade3f226SDamjan Jovanovic * to you under the Apache License, Version 2.0 (the 9*ade3f226SDamjan Jovanovic * "License"); you may not use this file except in compliance 10*ade3f226SDamjan Jovanovic * with the License. You may obtain a copy of the License at 11*ade3f226SDamjan Jovanovic * 12*ade3f226SDamjan Jovanovic * http://www.apache.org/licenses/LICENSE-2.0 13*ade3f226SDamjan Jovanovic * 14*ade3f226SDamjan Jovanovic * Unless required by applicable law or agreed to in writing, 15*ade3f226SDamjan Jovanovic * software distributed under the License is distributed on an 16*ade3f226SDamjan Jovanovic * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 17*ade3f226SDamjan Jovanovic * KIND, either express or implied. See the License for the 18*ade3f226SDamjan Jovanovic * specific language governing permissions and limitations 19*ade3f226SDamjan Jovanovic * under the License. 20*ade3f226SDamjan Jovanovic * 21*ade3f226SDamjan Jovanovic ***********************************************************--> 22*ade3f226SDamjan Jovanovic 23*ade3f226SDamjan Jovanovic 24*ade3f226SDamjan Jovanovic<project name="sdbc_hsqldb" default="main" basedir="."> 25*ade3f226SDamjan Jovanovic 26*ade3f226SDamjan Jovanovic <!-- ================================================================= --> 27*ade3f226SDamjan Jovanovic <!-- settings --> 28*ade3f226SDamjan Jovanovic <!-- ================================================================= --> 29*ade3f226SDamjan Jovanovic 30*ade3f226SDamjan Jovanovic <!-- global properties --> 31*ade3f226SDamjan Jovanovic <property file="../../../ant.properties"/> 32*ade3f226SDamjan Jovanovic <!-- version info --> 33*ade3f226SDamjan Jovanovic <property file="../../../solenv/inc/minor.mk"/> 34*ade3f226SDamjan Jovanovic 35*ade3f226SDamjan Jovanovic <!-- name of this sub target used in recursive builds --> 36*ade3f226SDamjan Jovanovic <property name="target" value="sdbc_hsqldb"/> 37*ade3f226SDamjan Jovanovic 38*ade3f226SDamjan Jovanovic <!-- name of jar file created, without .jar extension --> 39*ade3f226SDamjan Jovanovic <property name="jarname" value="sdbc_hsqldb"/> 40*ade3f226SDamjan Jovanovic 41*ade3f226SDamjan Jovanovic <!-- relative path to project directory --> 42*ade3f226SDamjan Jovanovic <property name="prj" value="../.."/> 43*ade3f226SDamjan Jovanovic 44*ade3f226SDamjan Jovanovic <!-- build output directory --> 45*ade3f226SDamjan Jovanovic <!-- FIXME: there are also extremely rare/obsolete dbcs/bndchk/truetime/hbtoolkit cases in main/solenv/inc/settings.mk --> 46*ade3f226SDamjan Jovanovic <condition property="out" value="${prj}/${OUTPATH}.cap"> 47*ade3f226SDamjan Jovanovic <isset property="${profile}"/> 48*ade3f226SDamjan Jovanovic </condition> 49*ade3f226SDamjan Jovanovic <condition property="out" value="${prj}/${OUTPATH}.pro"> 50*ade3f226SDamjan Jovanovic <isset property="${PRODUCT}"/> 51*ade3f226SDamjan Jovanovic </condition> 52*ade3f226SDamjan Jovanovic <property name="out" value="${prj}/${OUTPATH}"/> 53*ade3f226SDamjan Jovanovic 54*ade3f226SDamjan Jovanovic <!-- build directories --> 55*ade3f226SDamjan Jovanovic <property name="build.dir" value="${out}"/> 56*ade3f226SDamjan Jovanovic <property name="build.class" value="${build.dir}/class/${target}"/> 57*ade3f226SDamjan Jovanovic <property name="build.misc" value="${build.dir}/misc/${target}"/> 58*ade3f226SDamjan Jovanovic 59*ade3f226SDamjan Jovanovic <!-- start of java source code package structure --> 60*ade3f226SDamjan Jovanovic <property name="java.dir" value="src"/> 61*ade3f226SDamjan Jovanovic 62*ade3f226SDamjan Jovanovic <!-- define how to handle CLASSPATH environment --> 63*ade3f226SDamjan Jovanovic <property name="build.sysclasspath" value="ignore"/> 64*ade3f226SDamjan Jovanovic 65*ade3f226SDamjan Jovanovic <!-- classpath settings for compile and javadoc tasks --> 66*ade3f226SDamjan Jovanovic <condition property="jar-class-path" value="${HSQLDB_JAR}" else="hsqldb.jar"> 67*ade3f226SDamjan Jovanovic <equals arg1="${SYSTEM_HSQLDB}" arg2="YES"/> 68*ade3f226SDamjan Jovanovic </condition> 69*ade3f226SDamjan Jovanovic <property name="HSQLDB_JAR" value="${OUTDIR}/bin/hsqldb.jar"/> 70*ade3f226SDamjan Jovanovic <path id="classpath"> 71*ade3f226SDamjan Jovanovic <!-- 3rd party libs --> 72*ade3f226SDamjan Jovanovic <pathelement location="${HSQLDB_JAR}"/> 73*ade3f226SDamjan Jovanovic </path> 74*ade3f226SDamjan Jovanovic 75*ade3f226SDamjan Jovanovic <!-- name to display in documentation --> 76*ade3f226SDamjan Jovanovic <property name="docname" value="sdbc_hsqldb"/> 77*ade3f226SDamjan Jovanovic 78*ade3f226SDamjan Jovanovic <!-- set "modern" java compiler --> 79*ade3f226SDamjan Jovanovic <property name="build.compiler" value="modern"/> 80*ade3f226SDamjan Jovanovic 81*ade3f226SDamjan Jovanovic <!-- set wether we want to compile with debug information --> 82*ade3f226SDamjan Jovanovic <property name="debug" value="on"/> 83*ade3f226SDamjan Jovanovic 84*ade3f226SDamjan Jovanovic <!-- set wether we want to compile with optimisation --> 85*ade3f226SDamjan Jovanovic <property name="optimize" value="off"/> 86*ade3f226SDamjan Jovanovic 87*ade3f226SDamjan Jovanovic <!-- set wether we want to compile with or without deprecation --> 88*ade3f226SDamjan Jovanovic <property name="deprecation" value="on"/> 89*ade3f226SDamjan Jovanovic 90*ade3f226SDamjan Jovanovic <target name="info"> 91*ade3f226SDamjan Jovanovic <echo message="--------------------"/> 92*ade3f226SDamjan Jovanovic <echo message="${target}"/> 93*ade3f226SDamjan Jovanovic <echo message="--------------------"/> 94*ade3f226SDamjan Jovanovic </target> 95*ade3f226SDamjan Jovanovic 96*ade3f226SDamjan Jovanovic <!-- ================================================================= --> 97*ade3f226SDamjan Jovanovic <!-- custom targets --> 98*ade3f226SDamjan Jovanovic <!-- ================================================================= --> 99*ade3f226SDamjan Jovanovic 100*ade3f226SDamjan Jovanovic <!-- the main target, called in recursive builds --> 101*ade3f226SDamjan Jovanovic <target name="main" depends="info,prepare,compile,jar,javadoc,zipdoc"/> 102*ade3f226SDamjan Jovanovic 103*ade3f226SDamjan Jovanovic <!-- prepare output directories --> 104*ade3f226SDamjan Jovanovic <target name="prepare"> 105*ade3f226SDamjan Jovanovic <mkdir dir="${build.dir}"/> 106*ade3f226SDamjan Jovanovic <mkdir dir="${build.dir}/doc/${target}"/> 107*ade3f226SDamjan Jovanovic <mkdir dir="${build.class}"/> 108*ade3f226SDamjan Jovanovic <mkdir dir="${build.misc}"/> 109*ade3f226SDamjan Jovanovic </target> 110*ade3f226SDamjan Jovanovic 111*ade3f226SDamjan Jovanovic 112*ade3f226SDamjan Jovanovic <target name="res" depends="prepare"> 113*ade3f226SDamjan Jovanovic <copy todir="${build.class}"> 114*ade3f226SDamjan Jovanovic <fileset dir="${java.dir}"> 115*ade3f226SDamjan Jovanovic <include name="**/*.properties"/> 116*ade3f226SDamjan Jovanovic <include name="**/*.css"/> 117*ade3f226SDamjan Jovanovic <include name="**/*.dtd"/> 118*ade3f226SDamjan Jovanovic <include name="**/*.form"/> 119*ade3f226SDamjan Jovanovic <include name="**/*.gif "/> 120*ade3f226SDamjan Jovanovic <include name="**/*.htm"/> 121*ade3f226SDamjan Jovanovic <include name="**/*.html"/> 122*ade3f226SDamjan Jovanovic <include name="**/*.js"/> 123*ade3f226SDamjan Jovanovic <include name="**/*.mod"/> 124*ade3f226SDamjan Jovanovic <include name="**/*.sql"/> 125*ade3f226SDamjan Jovanovic <include name="**/*.xml"/> 126*ade3f226SDamjan Jovanovic <include name="**/*.xsl"/> 127*ade3f226SDamjan Jovanovic <include name="**/*.map"/> 128*ade3f226SDamjan Jovanovic 129*ade3f226SDamjan Jovanovic </fileset> 130*ade3f226SDamjan Jovanovic </copy> 131*ade3f226SDamjan Jovanovic </target> 132*ade3f226SDamjan Jovanovic 133*ade3f226SDamjan Jovanovic 134*ade3f226SDamjan Jovanovic <target name="compile" depends="prepare,res"> 135*ade3f226SDamjan Jovanovic <javac destdir="${build.class}" 136*ade3f226SDamjan Jovanovic debug="${debug}" 137*ade3f226SDamjan Jovanovic deprecation="${deprecation}" 138*ade3f226SDamjan Jovanovic optimize="${optimize}" 139*ade3f226SDamjan Jovanovic classpathref="classpath"> 140*ade3f226SDamjan Jovanovic <src path="${java.dir}"/> 141*ade3f226SDamjan Jovanovic <include name="**/*.java"/> 142*ade3f226SDamjan Jovanovic </javac> 143*ade3f226SDamjan Jovanovic </target> 144*ade3f226SDamjan Jovanovic 145*ade3f226SDamjan Jovanovic <!-- check if javadoc is up to date --> 146*ade3f226SDamjan Jovanovic <target name="javadoc_check" depends="prepare" if="build.dir"> 147*ade3f226SDamjan Jovanovic <uptodate property="javadocBuild.notRequired" value="true" 148*ade3f226SDamjan Jovanovic targetfile="${build.dir}/doc/${target}/${target}_javadoc.zip"> 149*ade3f226SDamjan Jovanovic <srcfiles dir="${java.dir}" includes="**/*.java"/> 150*ade3f226SDamjan Jovanovic </uptodate> 151*ade3f226SDamjan Jovanovic </target> 152*ade3f226SDamjan Jovanovic 153*ade3f226SDamjan Jovanovic <!-- generate java documentation --> 154*ade3f226SDamjan Jovanovic <target name="javadoc" depends="prepare,javadoc_check,compile" 155*ade3f226SDamjan Jovanovic unless="javadocBuild.notRequired" 156*ade3f226SDamjan Jovanovic if="build.dir"> 157*ade3f226SDamjan Jovanovic 158*ade3f226SDamjan Jovanovic <javadoc destdir="${build.dir}/doc/${target}/javadoc" 159*ade3f226SDamjan Jovanovic verbose="false" 160*ade3f226SDamjan Jovanovic author="false" 161*ade3f226SDamjan Jovanovic nodeprecated="true" 162*ade3f226SDamjan Jovanovic nodeprecatedlist="true" 163*ade3f226SDamjan Jovanovic use="true" 164*ade3f226SDamjan Jovanovic Doctitle="${docname}" 165*ade3f226SDamjan Jovanovic windowtitle="${docname}" 166*ade3f226SDamjan Jovanovic classpathref="classpath"> 167*ade3f226SDamjan Jovanovic 168*ade3f226SDamjan Jovanovic <packageset dir="${java.dir}" defaultexcludes="yes"> 169*ade3f226SDamjan Jovanovic <include name="com/**"/> 170*ade3f226SDamjan Jovanovic <include name="org/**"/> 171*ade3f226SDamjan Jovanovic </packageset> 172*ade3f226SDamjan Jovanovic 173*ade3f226SDamjan Jovanovic <link offline="true" href="http://java.sun.com/j2se/1.4.2/docs/api" 174*ade3f226SDamjan Jovanovic packagelistLoc="${common.doc}/jdk1.4.2"/> 175*ade3f226SDamjan Jovanovic <link offline="true" 176*ade3f226SDamjan Jovanovic href="http://java.sun.com/products/servlet/2.3/javadoc" 177*ade3f226SDamjan Jovanovic packagelistLoc="${common.doc}/servlet2.3"/> 178*ade3f226SDamjan Jovanovic <link offline="true" 179*ade3f226SDamjan Jovanovic href="http://logging.apache.org/log4j/docs/api" 180*ade3f226SDamjan Jovanovic packagelistLoc="${common.doc}/log4j-1.2.8"/> 181*ade3f226SDamjan Jovanovic <link offline="true" 182*ade3f226SDamjan Jovanovic href="http://java.sun.com/products/javabeans/glasgow/javadocs" 183*ade3f226SDamjan Jovanovic packagelistLoc="${common.doc}/jaf-1.0.2"/> 184*ade3f226SDamjan Jovanovic <link offline="true" 185*ade3f226SDamjan Jovanovic href="http://java.sun.com/products/javamail/javadocs" 186*ade3f226SDamjan Jovanovic packagelistLoc="${common.doc}/javamail-1.3.1"/> 187*ade3f226SDamjan Jovanovic <link offline="true" 188*ade3f226SDamjan Jovanovic href="http://ws.apache.org/soap/docs" 189*ade3f226SDamjan Jovanovic packagelistLoc="${common.doc}/soap-2.3.1"/> 190*ade3f226SDamjan Jovanovic 191*ade3f226SDamjan Jovanovic <bottom><i>Copyright &#169; 2004 Sun Microsystems, Inc., 901 San Antonio Road, Palo Alto, CA 94303 USA</i></bottom> 192*ade3f226SDamjan Jovanovic <header>${docname}</header> 193*ade3f226SDamjan Jovanovic 194*ade3f226SDamjan Jovanovic </javadoc> 195*ade3f226SDamjan Jovanovic </target> 196*ade3f226SDamjan Jovanovic 197*ade3f226SDamjan Jovanovic <!-- zip documentation and store in build/doc/${target} --> 198*ade3f226SDamjan Jovanovic <target name="zipdoc" depends="javadoc" if="build.dir" unless="javadocBuild.notRequired"> 199*ade3f226SDamjan Jovanovic <zip zipfile="${build.dir}/doc/${target}/${target}_javadoc.zip" 200*ade3f226SDamjan Jovanovic basedir="${build.dir}/doc/${target}/javadoc" 201*ade3f226SDamjan Jovanovic update="true"/> 202*ade3f226SDamjan Jovanovic </target> 203*ade3f226SDamjan Jovanovic 204*ade3f226SDamjan Jovanovic <!-- clean up --> 205*ade3f226SDamjan Jovanovic <target name="clean" depends="prepare"> 206*ade3f226SDamjan Jovanovic <delete dir="${build.class}" includeEmptyDirs="true"/> 207*ade3f226SDamjan Jovanovic <delete dir="${build.dir}/doc/${target}" includeEmptyDirs="true"/> 208*ade3f226SDamjan Jovanovic </target> 209*ade3f226SDamjan Jovanovic 210*ade3f226SDamjan Jovanovic <!-- create jar file --> 211*ade3f226SDamjan Jovanovic <target name="jar" depends="prepare,compile" if="build.class"> 212*ade3f226SDamjan Jovanovic <jar jarfile="${build.class}/${jarname}.jar" 213*ade3f226SDamjan Jovanovic basedir="${build.class}"> 214*ade3f226SDamjan Jovanovic <manifest> 215*ade3f226SDamjan Jovanovic <attribute name="Class-Path" value="${jar-class-path} .."/> 216*ade3f226SDamjan Jovanovic <attribute name="Solar-Version" value="${RSCREVISION}"/> 217*ade3f226SDamjan Jovanovic </manifest> 218*ade3f226SDamjan Jovanovic <include name="**/*.class"/> 219*ade3f226SDamjan Jovanovic <include name="**/*.properties"/> 220*ade3f226SDamjan Jovanovic <include name="**/*.css"/> 221*ade3f226SDamjan Jovanovic <include name="**/*.dtd"/> 222*ade3f226SDamjan Jovanovic <include name="**/*.form"/> 223*ade3f226SDamjan Jovanovic <include name="**/*.gif "/> 224*ade3f226SDamjan Jovanovic <include name="**/*.htm"/> 225*ade3f226SDamjan Jovanovic <include name="**/*.html"/> 226*ade3f226SDamjan Jovanovic <include name="**/*.js"/> 227*ade3f226SDamjan Jovanovic <include name="**/*.mod"/> 228*ade3f226SDamjan Jovanovic <include name="**/*.sql"/> 229*ade3f226SDamjan Jovanovic <include name="**/*.xml"/> 230*ade3f226SDamjan Jovanovic <include name="**/*.xsl"/> 231*ade3f226SDamjan Jovanovic <include name="**/*.map"/> 232*ade3f226SDamjan Jovanovic </jar> 233*ade3f226SDamjan Jovanovic </target> 234*ade3f226SDamjan Jovanovic 235*ade3f226SDamjan Jovanovic <target name="test" depends="prepare"> 236*ade3f226SDamjan Jovanovic </target> 237*ade3f226SDamjan Jovanovic 238*ade3f226SDamjan Jovanovic</project> 239*ade3f226SDamjan Jovanovic 240