| <!-- |
| Licensed to the Apache Software Foundation (ASF) under one or more |
| contributor license agreements. See the NOTICE file distributed with |
| this work for additional information regarding copyright ownership. |
| The ASF licenses this file to You under the Apache License, Version 2.0 |
| (the "License"); you may not use this file except in compliance with |
| the License. You may obtain a copy of the License at |
| |
| http://www.apache.org/licenses/LICENSE-2.0 |
| |
| Unless required by applicable law or agreed to in writing, software |
| distributed under the License is distributed on an "AS IS" BASIS, |
| WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| See the License for the specific language governing permissions and |
| limitations under the License. |
| --> |
| |
| <project default="all"> |
| |
| <target name="clean"> |
| <delete dir="build"/> |
| <delete dir="dist"/> |
| </target> |
| |
| <target name="calculate-condition"> |
| <available file="mxie-java/JavaMXIELIB.jar" property="mxieStatus"/> |
| <condition property="canBuild"> |
| <isset property="mxieStatus"/> |
| </condition> |
| </target> |
| |
| <target name="precompile-check" depends="calculate-condition" unless="canBuild"> |
| <echo message="Memex Connector cannot be built without JavaMXIELIB.jar"/> |
| </target> |
| |
| <target name="doc" depends="precompile-check" if="canBuild"> |
| <mkdir dir="dist/doc"/> |
| <javadoc destdir="dist/doc" classpath="mxie-java/JavaMXIELIB.jar:lib/servlet-api.jar:lib/jdbcpool-0.99.jar:lib/postgresql.jar:lib/commons-fileupload.jar:lib/serializer.jar:lib/log4j-1.2.jar:lib/commons-logging.jar:lib/commons-httpclient-lcf.jar:lib/mcf-core.jar:lib/mcf-agents.jar:lib/mcf-pull-agent.jar:lib/xml-apis.jar:lib/xalan2.jar:lib/commons-collections.jar:lib/commons-codec.jar:lib/commons-io.jar" source="1.5"> |
| <classpath> |
| <fileset dir="lib" includes="*.jar"/> |
| <fileset dir="mxie-java" includes="*.jar"/> |
| </classpath> |
| <fileset dir="connector/src/main/java" includes="**/*.java"/> |
| </javadoc> |
| </target> |
| |
| <target name="compile-connector" depends="precompile-check" if="canBuild"> |
| <mkdir dir="build/connector/classes"/> |
| <javac srcdir="connector/src/main/java" destdir="build/connector/classes" classpath="${classpath}" target="1.5" source="1.5" debug="true" debuglevel="lines,vars,source"> |
| <classpath> |
| <fileset dir="lib" includes="*.jar"/> |
| <fileset dir="mxie-java" includes="*.jar"/> |
| </classpath> |
| </javac> |
| </target> |
| |
| <target name="jar-connector" depends="compile-connector,precompile-check" if="canBuild"> |
| <mkdir dir="build/jar"/> |
| <jar destfile="build/jar/mcf-memex-connector.jar" basedir="build/connector/classes"/> |
| </target> |
| |
| <target name="lib" depends="jar-connector,precompile-check" if="canBuild"> |
| <mkdir dir="dist/lib"/> |
| <copy todir="dist/lib" file="build/jar/mcf-memex-connector.jar"/> |
| <copy todir="dist/lib"> |
| <fileset dir="mxie-java" includes="*.jar"/> |
| </copy> |
| </target> |
| |
| <target name="build" depends="lib"/> |
| <target name="build-tests"> |
| <mkdir dir="build/test-jar"/> |
| </target> |
| <target name="run-tests"/> |
| <target name="run-tests-postgresql"/> |
| <target name="run-tests-HSQLDB"/> |
| <target name="all" depends="build,doc,build-tests,run-tests,run-tests-postgresql,run-tests-HSQLDB"/> |
| |
| </project> |