commons-xml/build.xml
curcuru f77419e989 New build system for whole xml-commons project
Top-level xml-commons/build.xml creates distro out of all sub-sub-projects
README.html updated with forrest 1.5 look and more info
which.xml and external/build.xml simplified with minor updates; outputs are still the same


git-svn-id: https://svn.apache.org/repos/asf/xml/commons/trunk@225943 13f79535-47bb-0310-9956-ffa450edef68
2002-01-09 20:01:23 +00:00

93 lines
3.1 KiB
XML

<?xml version="1.0"?>
<!--
Simplistic meta-build file to call various other xml-commons build files.
Currently merely uses <ant> to build all subprojects, then
just creates a distribution out of all of them.
@author shane_curcuru@us.ibm.com
-->
<project name="xml-commons" default="all">
<!-- Name and version information -->
<!-- Versions like Xalan builds: major.minor [(isdeveloper release) | release] -->
<!-- Version flow:
1.0D01, 1.0D02, ... 1.0, (oops, fix old bug in 1.0): 1.0.1
1.1D01, ... 1.1
etc.
-->
<property name="version.major" value="1"/>
<property name="version.minor" value="0"/>
<property name="version.isdeveloper" value="D"/><!-- values: 'D'|'' -->
<property name="version.release" value="1"/>
<property name="version" value="${version.major}.${version.minor}.${version.isdeveloper}${version.release}" />
<!-- Allow properties following these statements to be overridden -->
<property file="build.properties"/>
<!-- Location of the system's temporary directory; all output sent here -->
<property name="tmp.dir" value="."/>
<!-- Overall distribution unit -->
<property name="dist.basename" value="xml-commons-${version}"/>
<property name="dist.dir" value="${tmp.dir}/build"/>
<!-- Public Targets -->
<target name="all"
depends="jars,dist"
description="Default all target; calls every sub-build file directly.">
</target>
<target name="external"
description="Calls just java/external/build.xml only.">
<ant dir="java/external" antfile="build.xml" target="all" >
</ant>
</target>
<target name="jars"
depends="external"
description="Calls all other java build files.">
<ant dir="java" antfile="which.xml" target="all" >
</ant>
</target>
<target name="dist"
description="Create simple distribution of all subprojects">
<mkdir dir="${dist.dir}/${dist.basename}"/>
<mkdir dir="${dist.dir}/${dist.basename}/java"/>
<!-- Copy all sources and their corresponding built files -->
<copy todir="${dist.dir}/${dist.basename}/java">
<!-- Assumption! Each subproject creates built files within itself -->
<fileset dir="java/"/>
</copy>
<!-- Copy pertinent top-level files -->
<copy todir="${dist.dir}/${dist.basename}">
<fileset dir="." includes="README.html,build.xml"/>
</copy>
<tar tarfile="${dist.dir}/${dist.basename}.tar" >
<tarfileset dir="${dist.dir}">
<include name="${dist.basename}/"/>
</tarfileset>
</tar>
<gzip zipfile="${dist.dir}/${dist.basename}.tar.gz" src="${dist.dir}/${dist.basename}.tar"/>
<delete file="${dist.dir}/${dist.basename}.tar" />
<zip zipfile="${dist.dir}/${dist.basename}.zip" >
<zipfileset dir="${dist.dir}">
<include name="${dist.basename}/"/>
</zipfileset>
</zip>
</target>
<target name="clean"
description="Cleanup all files in ${dist.dir} and subprojects">
<delete dir="${dist.dir}"/>
<ant dir="java/external" antfile="build.xml" target="clean" >
</ant>
<ant dir="java" antfile="which.xml" target="clean" >
</ant>
</target>
</project>