91 lines
2.7 KiB
XML
91 lines
2.7 KiB
XML
<?xml version="1.0"?>
|
|
<!DOCTYPE project>
|
|
<!-- Builds the XID Framework jar filen. -->
|
|
<project name="xid" default="all" basedir=".">
|
|
<property name="targetjar" value="xid.jar"/>
|
|
<property name="zip_file" value="xid.zip"/> <!-- Release zip file -->
|
|
<property name="src" value="src"/>
|
|
<property name="build" value="build"/>
|
|
<property name="doc" value="doc"/>
|
|
<property name="dist" value="dist"/>
|
|
<property name="resources" value="resources"/>
|
|
<property name="debug" value="on"/>
|
|
|
|
<target name="all" depends="compile,xid_dist,examples" />
|
|
|
|
<!-- ******* Init ******* -->
|
|
<target name="init">
|
|
<tstamp/>
|
|
<mkdir dir="${build}"/>
|
|
<mkdir dir="${build}/classes"/>
|
|
<mkdir dir="${dist}"/>
|
|
</target>
|
|
|
|
<!-- ******* Compile ******* -->
|
|
<target name="compile" depends="init">
|
|
<javac srcdir="${src}" destdir="${build}/classes" debug="${debug}" deprecation="on">
|
|
<classpath>
|
|
<fileset dir="lib" includes="**/*.jar"/>
|
|
</classpath>
|
|
</javac>
|
|
</target>
|
|
|
|
<!-- ****** xid.jar ****** -->
|
|
<target name="xid_dist" depends="compile">
|
|
<jar update="no" jarfile="dist/xid.jar">
|
|
<fileset dir="build/classes" includes="xid/**/**.class" />
|
|
<fileset dir="resources" includes="**" />
|
|
</jar>
|
|
</target>
|
|
|
|
|
|
<!-- ******* Examples (the webapp). ******* -->
|
|
<target name="examples" depends="xid_dist">
|
|
|
|
<copy todir="webapp-examples/WEB-INF/lib">
|
|
<fileset dir="lib" includes="*.jar" excludes="servlet-api.jar"/>
|
|
<fileset dir="dist" includes="*.jar"/>
|
|
</copy>
|
|
|
|
<copy file="${dist}/xid.jar" todir="webapp-examples/WEB-INF/lib" overwrite="yes" preservelastmodified="yes"/>
|
|
|
|
<delete>
|
|
<fileset dir="webapp-examples/WEB-INF/classes/" includes="**.class"/>
|
|
<fileset dir="webapp-examples/WEB-INF/classes/" includes="**/**.class"/>
|
|
</delete>
|
|
|
|
<javac srcdir="webapp-examples/WEB-INF/classes/" destdir="webapp-examples/WEB-INF/classes/" debug="${debug}" deprecation="on">
|
|
<classpath>
|
|
<fileset dir="webapp-examples/WEB-INF/lib" includes="**.jar"/>
|
|
</classpath>
|
|
</javac>
|
|
</target>
|
|
|
|
|
|
<!-- ****** JavaDoc ****** -->
|
|
<target name="javadoc" depends="compile">
|
|
<javadoc sourcepath="${src}" packageNames="xid.*" destdir="${doc}">
|
|
<classpath>
|
|
<fileset dir="lib" includes="**/*.jar"/>
|
|
</classpath>
|
|
</javadoc>
|
|
</target>
|
|
|
|
|
|
<!-- *************** Clean ***********************-->
|
|
<target name="clean">
|
|
<delete dir="${build}"/>
|
|
</target>
|
|
|
|
<!-- *********** Produce ZIP release file ******** -->
|
|
<target name="zip">
|
|
<zip update="no" zipfile="../${zip_file}" basedir=".">
|
|
<include name=".project" />
|
|
<include name=".classpath" />
|
|
<include name="build.xml" />
|
|
<include name="src/**" />
|
|
<include name="resources/**" />
|
|
<include name="lib/*.jar" />
|
|
</zip>
|
|
</target>
|
|
</project>
|