Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

476 lines (431 sloc) 18.728 kB
<?xml version="1.0" encoding="UTF-8"?>
<project name="pivot" default="build">
<property name="src" value="src"/>
<property name="bin" value="ant-bin"/>
<property name="lib" value="lib"/>
<property name="doc" value="doc"/>
<property name="charts" value="charts"/>
<property name="chartstest" value="charts-test"/>
<property name="core" value="core"/>
<property name="coretest" value="core-test"/>
<property name="web" value="web"/>
<property name="webtest" value="web-test"/>
<property name="wtk" value="wtk"/>
<property name="wtktest" value="wtk-test"/>
<tstamp/>
<property file="build.properties"/>
<!-- Compiler properties -->
<property name="compiler.optimize" value="true"/>
<property name="compiler.deprecation" value="true"/>
<property name="compiler.debug" value="true"/>
<target name="build" depends="charts, charts-test, core, core-test, web, web-test, wtk, wtk-test"/>
<target name="clean" depends="charts-clean, charts-test-clean, core-clean, core-test-clean, web-clean, web-test-clean, wtk-clean, wtk-test-clean"/>
<target name="doc">
<delete dir="${doc}"/>
<javadoc packagenames="pivot.*" destdir="${doc}" author="true" version="true" use="true">
<classpath>
<pathelement location="${charts}/lib/jcommon-1.0.12.jar"/>
<pathelement location="${charts}/lib/jfreechart-1.0.9.jar"/>
<pathelement location="${web}/lib/servlet-api.jar"/>
<pathelement location="${wtk}/lib/stax-api-1.0.jar"/>
<pathelement location="${wtk}/lib/stax-1.2.0.jar"/>
<fileset dir="${web}/${lib}" includes="**/*.jar"/>
</classpath>
<packageset dir="${charts}/${src}" includes="**/*"/>
<packageset dir="${core}/${src}" includes="**/*"/>
<packageset dir="${web}/${src}" includes="**/*"/>
<packageset dir="${wtk}/${src}" includes="**/*"/>
</javadoc>
<delete file="${ant.project.name}_${version}-${doc}.zip"/>
<zip destfile="${ant.project.name}_${version}-${doc}.zip" basedir="doc"/>
</target>
<!-- Build charts library -->
<target name="charts" depends="core, wtk">
<mkdir dir="${charts}/${bin}"/>
<!-- Compile source files -->
<javac srcdir="${charts}/${src}"
destDir="${charts}/${bin}"
optimize="${compiler.optimize}"
deprecation="${compiler.deprecation}"
debug="${compiler.debug}"
target="1.5"
failonerror="true">
<compilerarg value="-Xlint"/>
<classpath>
<pathelement location="${core}/${ant.project.name}-core.jar"/>
<pathelement location="${wtk}/${ant.project.name}-wtk.jar"/>
<pathelement location="${charts}/lib/jcommon-1.0.12.jar"/>
<pathelement location="${charts}/lib/jfreechart-1.0.9.jar"/>
</classpath>
</javac>
<!-- Rebuild the JAR file -->
<delete file="${charts}/${ant.project.name}-charts.jar"/>
<jar jarfile="${charts}/${ant.project.name}-charts.jar">
<manifest>
<attribute name="Sealed" value="true"/>
<attribute name="Built-On" value="${DSTAMP}-${TSTAMP}"/>
<attribute name="Version" value="${version}"/>
</manifest>
<fileset dir="${charts}/${bin}"/>
<fileset dir="${charts}/${src}">
<exclude name="**/*.java"/>
<exclude name="**/package.html"/>
</fileset>
</jar>
</target>
<target name="charts-clean">
<delete dir="${charts}/${bin}"/>
<delete file="${charts}/${ant.project.name}-charts.jar"/>
</target>
<!-- Charts Test -->
<target name="charts-test" depends="charts, core, wtk">
<mkdir dir="${chartstest}/${bin}"/>
<!-- Compile source files -->
<javac srcdir="${chartstest}/${src}"
destDir="${chartstest}/${bin}"
optimize="${compiler.optimize}"
deprecation="${compiler.deprecation}"
debug="${compiler.debug}"
target="1.5"
failonerror="true">
<compilerarg value="-Xlint"/>
<classpath>
<pathelement location="charts/pivot-charts.jar"/>
<pathelement location="core/pivot-core.jar"/>
<pathelement location="wtk/pivot-wtk.jar"/>
</classpath>
</javac>
<!-- Rebuild the JAR file -->
<delete file="${chartstest}/${ant.project.name}-charts.test.jar"/>
<jar jarfile="${chartstest}/${ant.project.name}-charts.test.jar">
<fileset dir="${chartstest}/${bin}"/>
<fileset dir="${chartstest}/${src}">
<exclude name="**/*.java"/>
<exclude name="**/package.html"/>
</fileset>
</jar>
</target>
<target name="charts-test-clean">
<delete dir="${chartstest}/${bin}"/>
<delete file="${chartstest}/${ant.project.name}-charts.test.jar"/>
</target>
<!-- Core -->
<target name="core">
<mkdir dir="${core}/${bin}"/>
<!-- Compile source files -->
<javac srcdir="${core}/${src}"
destDir="${core}/${bin}"
optimize="${compiler.optimize}"
deprecation="${compiler.deprecation}"
debug="${compiler.debug}"
target="1.5"
failonerror="true">
<compilerarg value="-Xlint"/>
</javac>
<!-- Rebuild the JAR file -->
<delete file="${core}/${ant.project.name}-core.jar"/>
<jar jarfile="${core}/${ant.project.name}-core.jar">
<manifest>
<attribute name="Sealed" value="true"/>
<attribute name="Built-On" value="${DSTAMP}-${TSTAMP}"/>
<attribute name="Version" value="${version}"/>
</manifest>
<fileset dir="${core}/${bin}"/>
<fileset dir="${core}/${src}">
<exclude name="**/*.java"/>
<exclude name="**/package.html"/>
</fileset>
</jar>
</target>
<target name="core-clean">
<delete dir="${core}/${bin}"/>
<delete file="${core}/${ant.project.name}-core.jar"/>
</target>
<!-- Core Test -->
<target name="core-test" depends="core">
<mkdir dir="${coretest}/${bin}"/>
<!-- Compile source files -->
<javac srcdir="${coretest}/${src}"
destDir="${coretest}/${bin}"
optimize="${compiler.optimize}"
deprecation="${compiler.deprecation}"
debug="${compiler.debug}"
target="1.5"
failonerror="true"
classpath="${core}/${ant.project.name}-core.jar:junit.jar">
<compilerarg value="-Xlint"/>
</javac>
<!-- Rebuild the JAR file -->
<delete file="${coretest}/${ant.project.name}-core.test.jar"/>
<jar jarfile="${coretest}/${ant.project.name}-core.test.jar">
<fileset dir="${coretest}/${bin}"/>
<fileset dir="${coretest}/${src}">
<exclude name="**/*.java"/>
<exclude name="**/package.html"/>
</fileset>
</jar>
</target>
<target name="core-test-clean">
<delete dir="${coretest}/${bin}"/>
<delete file="${coretest}/${ant.project.name}-core.test.jar"/>
</target>
<!-- Web -->
<target name="web">
<mkdir dir="${web}/${bin}"/>
<!-- Compile source files -->
<javac srcdir="${web}/${src}"
destDir="${web}/${bin}"
optimize="${compiler.optimize}"
deprecation="${compiler.deprecation}"
debug="${compiler.debug}"
target="1.5"
failonerror="true">
<compilerarg value="-Xlint"/>
<classpath>
<pathelement location="${core}/${ant.project.name}-core.jar"/>
<fileset dir="${web}/${lib}" includes="**/*.jar"/>
</classpath>
</javac>
<!-- Rebuild the JAR files -->
<delete file="${web}/${ant.project.name}-web.jar"/>
<jar jarfile="${web}/${ant.project.name}-web.jar">
<manifest>
<attribute name="Sealed" value="true"/>
<attribute name="Built-On" value="${DSTAMP}-${TSTAMP}"/>
<attribute name="Version" value="${version}"/>
</manifest>
<fileset dir="${web}/${bin}">
<exclude name="pivot/web/server/**"/>
</fileset>
<fileset dir="${web}/${src}">
<exclude name="pivot/web/server/**"/>
<exclude name="**/*.java"/>
<exclude name="**/package.html"/>
</fileset>
</jar>
<delete file="${web}/${ant.project.name}-web.server.jar"/>
<jar jarfile="${web}/${ant.project.name}-web.server.jar">
<manifest>
<attribute name="Sealed" value="true"/>
<attribute name="Built-On" value="${DSTAMP}-${TSTAMP}"/>
<attribute name="Version" value="${version}"/>
</manifest>
<fileset dir="${web}/${bin}">
<include name="pivot/web/server/*"/>
</fileset>
<fileset dir="${web}/${src}">
<include name="pivot/web/server/**"/>
<exclude name="**/*.java"/>
<exclude name="**/package.html"/>
</fileset>
</jar>
</target>
<target name="web-clean">
<delete dir="${web}/${bin}"/>
<delete file="${web}/${ant.project.name}-web.jar"/>
<delete file="${web}/${ant.project.name}-web.server.jar"/>
</target>
<!-- Web Test -->
<target name="web-test" depends="web">
<mkdir dir="${webtest}/${bin}"/>
<!-- Compile source files -->
<javac srcdir="${webtest}/${src}"
destDir="${webtest}/${bin}"
optimize="${compiler.optimize}"
deprecation="${compiler.deprecation}"
debug="${compiler.debug}"
target="1.5"
failonerror="true">
<compilerarg value="-Xlint"/>
<classpath>
<pathelement location="${core}/${ant.project.name}-core.jar"/>
<pathelement location="${web}/${ant.project.name}-web.jar"/>
<fileset dir="${web}/${lib}" includes="**/*.jar"/>
</classpath>
</javac>
<!-- Rebuild the client JAR file -->
<delete file="${webtest}/${ant.project.name}-web.test.jar"/>
<jar jarfile="${webtest}/${ant.project.name}-web.test.jar">
<fileset dir="${webtest}/${bin}">
<exclude name="pivot/web/test/server/**"/>
</fileset>
<fileset dir="${webtest}/${src}">
<exclude name="pivot/web/test/server/**"/>
<exclude name="**/*.java"/>
<exclude name="**/package.html"/>
</fileset>
</jar>
<!-- Rebuild the server WAR file -->
<mkdir dir="${webtest}/${lib}"/>
<copy file="${core}/${ant.project.name}-core.jar" todir="${webtest}/${lib}"/>
<copy file="${web}/${ant.project.name}-web.server.jar" todir="${webtest}/${lib}"/>
<delete file="${webtest}/${ant.project.name}_web_test.war"/>
<war destfile="${webtest}/${ant.project.name}_web_test.war" webxml="${webtest}/web.xml">
<classes dir="${webtest}/${bin}">
<include name="pivot/web/test/server/**"/>
</classes>
<classes dir="${webtest}/${src}">
<include name="pivot/web/test/server/**"/>
<exclude name="**/*.java"/>
<exclude name="**/package.html"/>
</classes>
<lib dir="${webtest}/${lib}"/>
</war>
</target>
<target name="web-test-clean">
<delete dir="${webtest}/${bin}"/>
<delete dir="${webtest}/${lib}"/>
<delete file="${webtest}/${ant.project.name}-web.test.jar"/>
<delete file="${webtest}/${ant.project.name}_web_test.war"/>
</target>
<!-- WTK -->
<target name="wtk" depends="core">
<mkdir dir="${wtk}/${bin}"/>
<!-- Compile source files -->
<javac srcdir="${wtk}/${src}"
destDir="${wtk}/${bin}"
optimize="${compiler.optimize}"
deprecation="${compiler.deprecation}"
debug="${compiler.debug}"
target="1.5"
failonerror="true">
<compilerarg value="-Xlint"/>
<classpath>
<pathelement location="${core}/${ant.project.name}-core.jar"/>
<pathelement location="${wtk}/lib/stax-api-1.0.jar"/>
<pathelement location="${wtk}/lib/stax-1.2.0.jar"/>
</classpath>
</javac>
<!-- Rebuild the JAR file -->
<delete file="${wtk}/${ant.project.name}-wtk.jar"/>
<jar jarfile="${wtk}/${ant.project.name}-wtk.jar">
<manifest>
<attribute name="Sealed" value="true"/>
<attribute name="Built-On" value="${DSTAMP}-${TSTAMP}"/>
<attribute name="Version" value="${version}"/>
</manifest>
<metainf dir="${wtk}">
<include name="services/**"/>
</metainf>
<fileset dir="${wtk}/${bin}">
<exclude name="pivot/wtk/skin/terra/**"/>
<exclude name="pivot/wtk/skin/obsidian/**"/>
</fileset>
<fileset dir="${wtk}/${src}">
<exclude name="pivot/wtk/skin/terra/**"/>
<exclude name="pivot/wtk/skin/obsidian/**"/>
<exclude name="**/*.java"/>
<exclude name="**/package.html"/>
</fileset>
</jar>
<delete file="${wtk}/${ant.project.name}-wtk.terra.jar"/>
<jar jarfile="${wtk}/${ant.project.name}-wtk.terra.jar">
<manifest>
<attribute name="Sealed" value="true"/>
<attribute name="Built-On" value="${DSTAMP}-${TSTAMP}"/>
<attribute name="Version" value="${version}"/>
</manifest>
<fileset dir="${wtk}/${bin}">
<include name="pivot/wtk/skin/terra/**"/>
</fileset>
<fileset dir="${wtk}/${src}">
<include name="pivot/wtk/skin/terra/**"/>
<exclude name="**/*.java"/>
<exclude name="**/package.html"/>
</fileset>
</jar>
<delete file="${wtk}/${ant.project.name}-wtk.obsidian.jar"/>
<jar jarfile="${wtk}/${ant.project.name}-wtk.obsidian.jar">
<manifest>
<attribute name="Sealed" value="true"/>
<attribute name="Built-On" value="${DSTAMP}-${TSTAMP}"/>
<attribute name="Version" value="${version}"/>
</manifest>
<fileset dir="${wtk}/${bin}">
<include name="pivot/wtk/skin/obsidian/**"/>
</fileset>
<fileset dir="${wtk}/${src}">
<include name="pivot/wtk/skin/obsidian/**"/>
<exclude name="**/*.java"/>
<exclude name="**/package.html"/>
</fileset>
</jar>
</target>
<target name="wtk-clean">
<delete dir="${wtk}/${bin}"/>
<delete file="${wtk}/${ant.project.name}-wtk.jar"/>
<delete file="${wtk}/${ant.project.name}-wtk.terra.jar"/>
<delete file="${wtk}/${ant.project.name}-wtk.obsidian.jar"/>
</target>
<!-- WTK Test -->
<target name="wtk-test" depends="core, wtk">
<mkdir dir="${wtktest}/${bin}"/>
<!-- Compile source files -->
<javac srcdir="${wtktest}/${src}"
destDir="${wtktest}/${bin}"
optimize="${compiler.optimize}"
deprecation="${compiler.deprecation}"
debug="${compiler.debug}"
target="1.5"
failonerror="true">
<compilerarg value="-Xlint"/>
<classpath>
<pathelement location="${core}/${ant.project.name}-core.jar"/>
<pathelement location="${wtk}/${ant.project.name}-wtk.jar"/>
</classpath>
</javac>
<!-- Rebuild the JAR file -->
<delete file="${wtktest}/${ant.project.name}-wtk.test.jar"/>
<jar jarfile="${wtktest}/${ant.project.name}-wtk.test.jar">
<fileset dir="${wtktest}/${bin}"/>
<fileset dir="${wtktest}/${src}">
<exclude name="**/*.java"/>
<exclude name="**/package.html"/>
</fileset>
</jar>
</target>
<target name="wtk-test-clean">
<delete dir="${wtktest}/${bin}"/>
<delete file="${wtktest}/${ant.project.name}-wtk.test.jar"/>
</target>
<!-- Package all binaries and source -->
<target name="package" depends="trim-whitespace, clean, build, doc">
<delete file="${ant.project.name}_${version}.zip"/>
<zip destfile="${ant.project.name}_${version}.zip">
<fileset dir="${charts}">
<include name="${ant.project.name}-charts.jar"/>
</fileset>
<fileset dir="${core}">
<include name="${ant.project.name}-core.jar"/>
</fileset>
<fileset dir="${web}">
<include name="${ant.project.name}-web.jar"/>
</fileset>
<fileset dir="${wtk}">
<include name="${ant.project.name}-wtk.jar"/>
<include name="${ant.project.name}-wtk.terra.jar"/>
</fileset>
</zip>
<delete file="${ant.project.name}_${version}-src.zip"/>
<zip destfile="${ant.project.name}_${version}-src.zip">
<fileset dir="${charts}/${src}"/>
<fileset dir="${core}/${src}"/>
<fileset dir="${web}/${src}"/>
<fileset dir="${wtk}/${src}"/>
</zip>
</target>
<!-- Remove trailing white space in all source files -->
<target name="trim-whitespace">
<replaceregexp match="[\t ]+$" replace="" flags="gm" byline="true">
<fileset dir=".">
<include name="**/*.java"/>
<include name="**/*.html"/>
<include name="**/*.txt"/>
<include name="**/*.properties"/>
<include name="**/*.xml"/>
<include name="**/*.wtkx"/>
<include name="**/*.json"/>
</fileset>
</replaceregexp>
</target>
</project>
Jump to Line
Something went wrong with that request. Please try again.