Revamped build to use Maven Ant tasks, prepped a POM for proper publishing.
git-svn-id: svn+ssh://src.earth.threerings.net/vilya/trunk@996 c613c5cb-e716-0410-b11b-feb51c14d237
This commit is contained in:
@@ -1,89 +1,67 @@
|
||||
<?xml version="1.0" standalone="yes"?>
|
||||
<!-- build configuration -->
|
||||
<project name="vilya" default="compile" basedir=".">
|
||||
|
||||
<!-- import overriding properties -->
|
||||
<property file="build.properties"/>
|
||||
|
||||
<!-- configuration parameters -->
|
||||
<property name="lib.name" value="vilya"/>
|
||||
<project name="vilya" default="compile" basedir="." xmlns:artifact="urn:maven-artifact-ant">
|
||||
<property name="deploy.dir" value="dist"/>
|
||||
<property name="savedoc.dir" value="docs"/>
|
||||
<property name="src.dir" value="src/main/java"/>
|
||||
<property name="tsrc.dir" value="src/test/java"/>
|
||||
<property name="asrc.dir" value="src/main/as"/>
|
||||
|
||||
<!-- derived properties -->
|
||||
<property name="javadoc.home" value="${deploy.dir}/docs"/>
|
||||
<property name="classes.dir" value="${deploy.dir}/classes"/>
|
||||
<property name="tclasses.dir" value="${deploy.dir}/test-classes"/>
|
||||
<property name="tclasses.dir" value="${deploy.dir}/test-classes"/>
|
||||
|
||||
<!-- import some targets to enumerate library dependencies -->
|
||||
<property name="libs.dir" value="lib"/>
|
||||
<import file="etc/libs-incl.xml"/>
|
||||
<import file="etc/depends-incl.xml"/>
|
||||
<property name="maven-ant.vers" value="2.1.1"/>
|
||||
<property name="maven-ant.dir" value="${user.home}/.m2/ant-support"/>
|
||||
<property name="maven-ant.jar" value="${maven-ant.dir}/maven-ant-tasks-${maven-ant.vers}.jar"/>
|
||||
<property name="maven-ant.url"
|
||||
value="http://mirrors.ibiblio.org/pub/mirrors/apache/maven/binaries"/>
|
||||
<condition property="maven-ant.exists"><available file="${maven-ant.jar}"/></condition>
|
||||
<target name="-download-maven-ant" unless="maven-ant.exists">
|
||||
<mkdir dir="${maven-ant.dir}"/>
|
||||
<get src="${maven-ant.url}/maven-ant-tasks-${maven-ant.vers}.jar"
|
||||
dest="${maven-ant.jar}" usetimestamp="true"/>
|
||||
</target>
|
||||
|
||||
<!-- declare our classpath business -->
|
||||
<path id="classpath">
|
||||
<pathelement location="${classes.dir}"/>
|
||||
<fileset dir="${deploy.dir}/lib" includes="**/*.jar"/>
|
||||
</path>
|
||||
<path id="test.classpath">
|
||||
<path refid="classpath"/>
|
||||
<pathelement location="${tclasses.dir}"/>
|
||||
</path>
|
||||
<target name="-init-maven-ant" depends="-download-maven-ant">
|
||||
<taskdef resource="org/apache/maven/artifact/ant/antlib.xml"
|
||||
uri="urn:maven-artifact-ant" classpath="${maven-ant.jar}"/>
|
||||
<artifact:pom id="pom" file="pom.xml"/>
|
||||
<artifact:dependencies pathId="compile.classpath" pomRefId="pom" useScope="compile"/>
|
||||
<artifact:dependencies pathId="testlibs.classpath" pomRefId="pom" useScope="test"/>
|
||||
</target>
|
||||
|
||||
<!-- prepares the application directories -->
|
||||
<target name="prepare">
|
||||
<target name="-prepare" depends="-init-maven-ant">
|
||||
<mkdir dir="${deploy.dir}"/>
|
||||
<mkdir dir="${deploy.dir}/lib"/>
|
||||
<mkdir dir="${classes.dir}"/>
|
||||
<mkdir dir="${classes.dir}/rsrc"/>
|
||||
<mkdir dir="${javadoc.home}"/>
|
||||
<copy todir="${classes.dir}">
|
||||
<fileset dir="${src.dir}" includes="**/*.properties"/>
|
||||
<fileset dir="${src.dir}" includes="**/*.tmpl"/>
|
||||
</copy>
|
||||
<copy todir="${classes.dir}/rsrc">
|
||||
<fileset dir="rsrc" includes="**/*" excludes="**/bundles/**"/>
|
||||
</copy>
|
||||
<copy todir="${deploy.dir}/lib" flatten="true">
|
||||
<fileset refid="${lib.name}.libs"/>
|
||||
</copy>
|
||||
<path id="built.classpath">
|
||||
<path refid="compile.classpath"/>
|
||||
<pathelement location="${classes.dir}"/>
|
||||
</path>
|
||||
<path id="test.classpath">
|
||||
<path refid="testlibs.classpath"/>
|
||||
<pathelement location="${classes.dir}"/>
|
||||
<pathelement location="${tclasses.dir}"/>
|
||||
</path>
|
||||
</target>
|
||||
|
||||
<!-- makes sure our tools are compiled and defines the ant tasks -->
|
||||
<target name="preptools" depends="prepare">
|
||||
<taskdef resource="com/threerings/presents/tools.properties" classpathref="classpath"/>
|
||||
<target name="-preptools" depends="-prepare">
|
||||
<taskdef resource="com/threerings/presents/tools.properties" classpathref="compile.classpath"/>
|
||||
</target>
|
||||
|
||||
<!-- cleans out the intermediate build files -->
|
||||
<target name="clean" depends="common-clean">
|
||||
<target name="clean" description="Cleans out build results">
|
||||
<delete dir="${deploy.dir}/classes"/>
|
||||
<delete dir="${deploy.dir}/docs"/>
|
||||
<delete failonerror="false"><fileset dir="${deploy.dir}" includes="*.jar"/></delete>
|
||||
<delete failonerror="false"><fileset dir="${deploy.dir}" includes="*.swc"/></delete>
|
||||
</target>
|
||||
|
||||
<!-- wipes the entire build directory clean -->
|
||||
<target name="distclean" depends="common-clean">
|
||||
<target name="distclean" description="Scorched earth clean">
|
||||
<delete dir="${deploy.dir}"/>
|
||||
</target>
|
||||
|
||||
<!-- common clean tasks -->
|
||||
<target name="common-clean">
|
||||
<ant dir="tests" target="clean"/>
|
||||
</target>
|
||||
|
||||
<!-- build the java class files -->
|
||||
<target name="compile" depends="check-available,prepare">
|
||||
<target name="compile" depends="-prepare" description="Builds the Java code.">
|
||||
<mkdir dir="${classes.dir}"/>
|
||||
<copy todir="${classes.dir}"><fileset dir="src/main/resources" includes="**"/></copy>
|
||||
<javac srcdir="${src.dir}" destdir="${classes.dir}" includeAntRuntime="false"
|
||||
debug="on" optimize="${build.optimize}" deprecation="on"
|
||||
source="1.5" target="1.5">
|
||||
<classpath refid="classpath"/>
|
||||
<exclude name="com/threerings/**/tools/xml/**" unless="build.xml"/>
|
||||
<exclude name="com/threerings/**/tools/editor/**" unless="build.xml"/>
|
||||
<exclude name="com/threerings/**/tools/viewer/**" unless="build.xml"/>
|
||||
debug="on" optimize="${build.optimize}" deprecation="on" source="1.5" target="1.5">
|
||||
<classpath refid="compile.classpath"/>
|
||||
<compilerarg value="-Xlint"/>
|
||||
<compilerarg value="-Xlint:-serial"/>
|
||||
<compilerarg value="-Xlint:-unchecked"/> <!-- TODO: fix -->
|
||||
@@ -99,22 +77,24 @@
|
||||
</javac>
|
||||
</target>
|
||||
|
||||
<!-- checks whether our Flash library needs building -->
|
||||
<target name="checkaslib">
|
||||
<condition property="no_build_aslib"><or>
|
||||
<target name="-checkaslib">
|
||||
<condition property="no_build_aslib">
|
||||
<not><available file="${flexsdk.dir}/lib/compc.jar"/></not>
|
||||
</condition>
|
||||
<condition property="no_rebuild_aslib"><or>
|
||||
<isset property="no_build_aslib"/>
|
||||
<uptodate targetfile="${deploy.dir}/${lib.name}lib.swc">
|
||||
<srcfiles dir="${asrc.dir}" includes="**/*.as"/>
|
||||
</uptodate>
|
||||
</or></condition>
|
||||
</target>
|
||||
|
||||
<!-- builds our Flash library -->
|
||||
<target name="aslib" unless="no_build_aslib" depends="checkaslib">
|
||||
<target name="aslib" unless="no_rebuild_aslib" depends="-checkaslib"
|
||||
description="Builds the ActionScript code">
|
||||
<copy file="etc/aslib-config.xml.in" tofile="${deploy.dir}/aslib-config.xml">
|
||||
<filterset>
|
||||
<filter token="flex_sdk_dir" value="${flexsdk.dir}"/>
|
||||
<filter token="lib_name" value="${lib.name}"/>
|
||||
<filter token="lib_name" value="${ant.project.name}"/>
|
||||
</filterset>
|
||||
</copy>
|
||||
<java jar="${flexsdk.dir}/lib/compc.jar" fork="true" failonerror="true">
|
||||
@@ -124,41 +104,27 @@
|
||||
<arg value="-compiler.source-path=${asrc.dir}/"/>
|
||||
<arg value="-include-sources=${asrc.dir}/"/>
|
||||
<arg value="-output"/>
|
||||
<arg value="${deploy.dir}/${lib.name}lib.swc"/>
|
||||
<arg value="${deploy.dir}/${ant.project.name}lib.swc"/>
|
||||
</java>
|
||||
<delete file="${deploy.dir}/aslib-config.xml"/>
|
||||
</target>
|
||||
|
||||
<!-- builds the javadoc documentation -->
|
||||
<target name="javadoc" depends="prepare">
|
||||
<target name="javadoc" depends="-prepare" description="Builds the Java documentation">
|
||||
<mkdir dir="${deploy.dir}/docs"/>
|
||||
<javadoc sourcepath="${src.dir}" packagenames="com.threerings.*"
|
||||
destdir="${javadoc.home}" stylesheetfile="docs/stylesheet.css"
|
||||
destdir="${deploy.dir}/docs" stylesheetfile="docs/stylesheet.css"
|
||||
additionalparam="-breakiterator"
|
||||
link="http://www.threerings.net/code/vilya/docs/api">
|
||||
<classpath refid="classpath"/>
|
||||
<classpath refid="compile.classpath"/>
|
||||
<link href="http://java.sun.com/j2se/1.5/docs/api/"/>
|
||||
<!-- ant documentation is not available online, sorry kids -->
|
||||
<link href="file:///usr/share/doc/ant-doc/javadocs"/>
|
||||
<link href="http://samskivert.com/code/samskivert/samskivert/docs/api"/>
|
||||
<link href="http://www.threerings.net/code/narya/docs/api"/>
|
||||
<link href="http://www.threerings.net/code/nenya/docs/api"/>
|
||||
</javadoc>
|
||||
<copy todir="${javadoc.home}">
|
||||
<copy todir="${deploy.dir}/docs">
|
||||
<fileset dir="${src.dir}" includes="**/*.png"/>
|
||||
</copy>
|
||||
</target>
|
||||
|
||||
<!-- builds the javadocs and stuffs them in a directory where they won't
|
||||
be blown away when we do "clean" next time -->
|
||||
<target name="savedoc" depends="javadoc">
|
||||
<delete dir="${savedoc.dir}/api"/>
|
||||
<copy todir="${savedoc.dir}/api">
|
||||
<fileset dir="${javadoc.home}" includes="**/*"/>
|
||||
</copy>
|
||||
</target>
|
||||
|
||||
<!-- builds the ActionScript documention -->
|
||||
<target name="asdoc" unless="no_build_aslib" depends="checkaslib">
|
||||
<target name="asdoc" unless="no_build_aslib" depends="-checkaslib"
|
||||
description="Builds the ActionScript documention">
|
||||
<mkdir dir="${deploy.dir}/asdocs"/>
|
||||
<java classpath="${flexsdk.dir}/lib/asdoc.jar" classname="flex2.tools.ASDoc" fork="true">
|
||||
<jvmarg value="-Xmx1024m"/>
|
||||
@@ -174,87 +140,90 @@
|
||||
</java>
|
||||
</target>
|
||||
|
||||
<!-- builds and runs our tests -->
|
||||
<target name="tests">
|
||||
<ant dir="tests" target="test"/>
|
||||
<property name="test" value=""/>
|
||||
<target name="tests" depends="compile"
|
||||
description="Runs unit tests. Use -Dtest=Foo to run only FooTest.">
|
||||
<taskdef name="unit" classpathref="test.classpath"
|
||||
classname="org.apache.tools.ant.taskdefs.optional.junit.JUnitTask"/>
|
||||
<unit printsummary="off" haltonfailure="yes">
|
||||
<classpath refid="test.classpath"/>
|
||||
<sysproperty key="test_dir" value="${tclasses.dir}"/>
|
||||
<formatter type="brief" usefile="false"/>
|
||||
<batchtest>
|
||||
<fileset dir="${tsrc.dir}" includes="**/*${test}*Test.java"/>
|
||||
</batchtest>
|
||||
</unit>
|
||||
</target>
|
||||
|
||||
<!-- a target for rebuilding everything -->
|
||||
<target name="all" depends="clean,dist,javadoc,dist"/>
|
||||
|
||||
<!-- builds our distribution files (war and jar) -->
|
||||
<target name="dist" depends="prepare,compile,procstream,aslib">
|
||||
<!-- build our various jar files -->
|
||||
<jar destfile="${deploy.dir}/${lib.name}-parlor.jar">
|
||||
<target name="dist" depends="compile,procstream,aslib" description="Builds jar files.">
|
||||
<jar destfile="${deploy.dir}/${ant.project.name}-parlor.jar">
|
||||
<fileset dir="${classes.dir}" includes="rsrc/i18n/game/**"/>
|
||||
<fileset dir="${classes.dir}" includes="com/threerings/parlor/**"/>
|
||||
<fileset dir="${classes.dir}" includes="com/threerings/ezgame/**"/>
|
||||
</jar>
|
||||
<jar destfile="${deploy.dir}/${lib.name}-puzzle.jar">
|
||||
<jar destfile="${deploy.dir}/${ant.project.name}-puzzle.jar">
|
||||
<fileset dir="${classes.dir}" includes="com/threerings/puzzle/**"/>
|
||||
</jar>
|
||||
<jar destfile="${deploy.dir}/${lib.name}-micasa.jar">
|
||||
<jar destfile="${deploy.dir}/${ant.project.name}-micasa.jar">
|
||||
<fileset dir="${classes.dir}" includes="com/threerings/micasa/**"/>
|
||||
<fileset dir="${classes.dir}" includes="rsrc/**/micasa/**"/>
|
||||
</jar>
|
||||
<jar destfile="${deploy.dir}/${lib.name}-stage.jar">
|
||||
<jar destfile="${deploy.dir}/${ant.project.name}-stage.jar">
|
||||
<fileset dir="${classes.dir}" includes="com/threerings/stage/**"/>
|
||||
<fileset dir="${classes.dir}" includes="rsrc/**/stage/**"/>
|
||||
</jar>
|
||||
<jar destfile="${deploy.dir}/${lib.name}-stats.jar">
|
||||
<jar destfile="${deploy.dir}/${ant.project.name}-stats.jar">
|
||||
<fileset dir="${classes.dir}" includes="com/threerings/stats/**"/>
|
||||
<fileset dir="${classes.dir}" includes="rsrc/**/stats/**"/>
|
||||
</jar>
|
||||
<jar destfile="${deploy.dir}/${lib.name}-whirled.jar">
|
||||
<jar destfile="${deploy.dir}/${ant.project.name}-whirled.jar">
|
||||
<fileset dir="${classes.dir}" includes="com/threerings/whirled/**" excludes="**/*.png"/>
|
||||
<fileset dir="${classes.dir}" includes="rsrc/**/whirled/**"/>
|
||||
</jar>
|
||||
</target>
|
||||
|
||||
<!-- generates fields for persistent record classes -->
|
||||
<target name="genrecord" depends="preptools">
|
||||
<target name="genrecord" depends="-prepare"
|
||||
description="Generates fields for persistent record classes.">
|
||||
<taskdef name="grecord" classname="com.samskivert.depot.tools.GenRecordTask"
|
||||
classpathref="classpath"/>
|
||||
classpathref="compile.classpath"/>
|
||||
<!-- make sure the record class files are all compiled -->
|
||||
<javac srcdir="${src.dir}" destdir="${classes.dir}"
|
||||
debug="on" optimize="${build.optimize}" deprecation="on">
|
||||
<classpath refid="classpath"/>
|
||||
<classpath refid="compile.classpath"/>
|
||||
<include name="**/*Record.java"/>
|
||||
</javac>
|
||||
<!-- now update the source files -->
|
||||
<grecord classpathref="classpath">
|
||||
<grecord classpathref="built.classpath">
|
||||
<fileset dir="${src.dir}" includes="**/*Record.java"/>
|
||||
</grecord>
|
||||
</target>
|
||||
|
||||
<!-- generates additional methods for distributed object classes -->
|
||||
<target name="gendobj" depends="preptools">
|
||||
<target name="gendobj" depends="-preptools"
|
||||
description="Generates additional methods for distributed object classes">
|
||||
<!-- make sure the dobject class files are all compiled -->
|
||||
<javac srcdir="${src.dir}" destdir="${classes.dir}" includeAntRuntime="false"
|
||||
debug="on" optimize="${build.optimize}" deprecation="on"
|
||||
source="1.5" target="1.5">
|
||||
<classpath refid="classpath"/>
|
||||
source="1.5" target="1.5" classpathref="compile.classpath">
|
||||
<include name="**/*Object.java"/>
|
||||
</javac>
|
||||
<!-- now generate the associated files -->
|
||||
<gendobj classpathref="classpath">
|
||||
<gendobj classpathref="built.classpath">
|
||||
<fileset dir="${src.dir}" includes="**/*Object.java"/>
|
||||
</gendobj>
|
||||
</target>
|
||||
|
||||
<!-- generates marshaller and dispatcher classes for all invocation -->
|
||||
<!-- service declarations -->
|
||||
<target name="genservice" depends="preptools">
|
||||
<target name="genservice" depends="-preptools"
|
||||
description="Generates marshaller and dispatcher classes for all invocation services">
|
||||
<!-- make sure the service class files are all compiled -->
|
||||
<javac srcdir="${src.dir}" destdir="${classes.dir}" includeAntRuntime="false"
|
||||
debug="on" optimize="${build.optimize}" deprecation="on"
|
||||
source="1.5" target="1.5">
|
||||
<classpath refid="classpath"/>
|
||||
<classpath refid="compile.classpath"/>
|
||||
<include name="**/*Service.java"/>
|
||||
<exclude name="**/InvocationService.java"/>
|
||||
</javac>
|
||||
<!-- generate our services that have no ActionScript counterpart -->
|
||||
<genservice header="lib/SOURCE_HEADER" classpathref="classpath">
|
||||
<genservice header="lib/SOURCE_HEADER" classpathref="built.classpath">
|
||||
<fileset dir="${src.dir}">
|
||||
<include name="**/puzzle/client/*Service.java"/>
|
||||
<include name="**/micasa/simulator/client/*Service.java"/>
|
||||
@@ -264,7 +233,7 @@
|
||||
<providerless service="SimulatorService"/>
|
||||
</genservice>
|
||||
<!-- generate our services that have an ActionScript counterpart -->
|
||||
<genservice header="lib/SOURCE_HEADER" asroot="${asrc.dir}" classpathref="classpath">
|
||||
<genservice header="lib/SOURCE_HEADER" asroot="${asrc.dir}" classpathref="built.classpath">
|
||||
<fileset dir="${src.dir}">
|
||||
<include name="**/client/*Service.java"/>
|
||||
<exclude name="**/puzzle/client/*Service.java"/>
|
||||
@@ -274,35 +243,34 @@
|
||||
</genservice>
|
||||
</target>
|
||||
|
||||
<!-- generates sender and decoder classes for all invocation -->
|
||||
<!-- receiver declarations -->
|
||||
<target name="genreceiver" depends="preptools">
|
||||
<target name="genreceiver" depends="-preptools"
|
||||
description="Generates sender and decoder classes for all invocation receivers">
|
||||
<!-- make sure the receiver class files are all compiled -->
|
||||
<javac srcdir="${src.dir}" destdir="${classes.dir}" includeAntRuntime="false"
|
||||
debug="on" optimize="${build.optimize}" deprecation="on"
|
||||
source="1.5" target="1.5">
|
||||
<classpath refid="classpath"/>
|
||||
<classpath refid="compile.classpath"/>
|
||||
<include name="**/*Receiver.java"/>
|
||||
<exclude name="**/InvocationReceiver.java"/>
|
||||
</javac>
|
||||
<!-- now generate the associated files -->
|
||||
<genreceiver header="lib/SOURCE_HEADER" classpathref="classpath">
|
||||
<genreceiver header="lib/SOURCE_HEADER" classpathref="built.classpath">
|
||||
<fileset dir="${src.dir}" includes="**/*Receiver.java"
|
||||
excludes="**/InvocationReceiver.java"/>
|
||||
</genreceiver>
|
||||
</target>
|
||||
|
||||
<!-- adds readField and writeField methods to Streamable classes -->
|
||||
<target name="procstream" depends="preptools">
|
||||
<target name="procstream" depends="-preptools"
|
||||
description="Adds readField and writeField methods to Streamable classes">
|
||||
<!-- now instrument the associated files -->
|
||||
<instream outdir="${classes.dir}">
|
||||
<path refid="classpath"/>
|
||||
<path refid="built.classpath"/>
|
||||
<fileset dir="${classes.dir}" includes="**/*.class"/>
|
||||
</instream>
|
||||
</target>
|
||||
|
||||
<!-- generates ActionScript versions of our Streamable classes -->
|
||||
<target name="genascript" depends="preptools">
|
||||
<target name="genascript" depends="-preptools"
|
||||
description="Generates ActionScript versions of our Streamable classes">
|
||||
<!-- now generate the associated files -->
|
||||
<genascript header="lib/SOURCE_HEADER" asroot="${asrc.dir}">
|
||||
<fileset dir="${src.dir}">
|
||||
@@ -318,116 +286,4 @@
|
||||
</fileset>
|
||||
</genascript>
|
||||
</target>
|
||||
|
||||
<!-- a helper task for 'retro' -->
|
||||
<target name="vweave">
|
||||
<!-- various bits used by the retroweaver tasks -->
|
||||
<taskdef name="weave" classpathref="classpath"
|
||||
classname="com.rc.retroweaver.ant.RetroWeaverTask"/>
|
||||
<property name="inpre" value="${deploy.dir}/${lib.name}"/>
|
||||
<property name="outpre" value="${deploy.dir}/retro/${lib.name}"/>
|
||||
<path id="retrocp">
|
||||
<pathelement location="/usr/local/jdk1.4/jre/lib/rt.jar"/>
|
||||
<fileset dir="lib" includes="**/*.jar"/>
|
||||
<fileset dir="${deploy.dir}/retro" includes="*.jar"/>
|
||||
</path>
|
||||
<weave inputjar="${inpre}-${which}.jar" outputjar="${outpre}-${which}.jar"
|
||||
failonerror="true">
|
||||
<classpath refid="retrocp"/>
|
||||
</weave>
|
||||
</target>
|
||||
|
||||
<!-- converts our 1.5 code to a 1.4 compatible format -->
|
||||
<target name="retro" depends="dist">
|
||||
<mkdir dir="${deploy.dir}/retro"/>
|
||||
|
||||
<!-- we weave everything a first time without verification so that -->
|
||||
<!-- interdependencies will resolve the second time -->
|
||||
<weave inputjar="${inpre}-micasa.jar" outputjar="${outpre}-micasa.jar"/>
|
||||
<weave inputjar="${inpre}-parlor.jar" outputjar="${outpre}-parlor.jar"/>
|
||||
<weave inputjar="${inpre}-puzzle.jar" outputjar="${outpre}-puzzle.jar"/>
|
||||
<weave inputjar="${inpre}-stage.jar" outputjar="${outpre}-stage.jar"/>
|
||||
<weave inputjar="${inpre}-stats.jar" outputjar="${outpre}-stats.jar"/>
|
||||
<weave inputjar="${inpre}-whirled.jar" outputjar="${outpre}-whirled.jar"/>
|
||||
|
||||
<!-- now weave again with the verifier to check for unweavable 1.5isms -->
|
||||
<antcall target="vweave"><param name="which" value="micasa"/></antcall>
|
||||
<antcall target="vweave"><param name="which" value="parlor"/></antcall>
|
||||
<antcall target="vweave"><param name="which" value="puzzle"/></antcall>
|
||||
<antcall target="vweave"><param name="which" value="stage"/></antcall>
|
||||
<antcall target="vweave"><param name="which" value="stats"/></antcall>
|
||||
<antcall target="vweave"><param name="which" value="whirled"/></antcall>
|
||||
</target>
|
||||
|
||||
<!-- generate a class hierarchy diagram -->
|
||||
<target name="hierviz" depends="prepare,compile">
|
||||
<taskdef name="viztool" classname="com.samskivert.viztool.DriverTask"/>
|
||||
<viztool visualizer="com.samskivert.viztool.hierarchy.HierarchyVisualizer"
|
||||
pkgroot="com.threerings.miso" classes="com.threerings.miso.*"
|
||||
output="hierviz.ps">
|
||||
<classpath refid="classpath"/>
|
||||
</viztool>
|
||||
</target>
|
||||
|
||||
<!-- generate a class hierarchy diagram -->
|
||||
<target name="sumgen" depends="prepare,compile">
|
||||
<taskdef name="viztool" classname="com.samskivert.viztool.DriverTask"/>
|
||||
<viztool visualizer="com.samskivert.viztool.summary.SummaryVisualizer"
|
||||
pkgroot="com.threerings.miso"
|
||||
classes="com.threerings.miso.*Scene.*"
|
||||
output="summary.ps">
|
||||
<classpath refid="base.classpath"/>
|
||||
</viztool>
|
||||
</target>
|
||||
|
||||
<!-- creates a tarball and zipfile for source distribution -->
|
||||
<target name="distrib">
|
||||
<echo message="You may want to stop and run 'ant savedoc' first."/>
|
||||
<echo message="Building snapshot tar.gz distribution..."/>
|
||||
<tar destfile="../vilya-snapshot.tar.gz" compression="gzip">
|
||||
<tarfileset dir=".." mode="0664" dirmode="0775">
|
||||
<include name="vilya/**"/>
|
||||
<exclude name="**/.svn"/>
|
||||
<exclude name="vilya/tests/dist/**"/>
|
||||
<exclude name="vilya/dist/**"/>
|
||||
<exclude name="vilya/code/**"/>
|
||||
<exclude name="vilya/vilya-*.*"/>
|
||||
</tarfileset>
|
||||
</tar>
|
||||
<echo message="Building snapshot zip distribution..."/>
|
||||
<zip destfile="../vilya-snapshot.zip">
|
||||
<fileset dir="..">
|
||||
<include name="vilya/**"/>
|
||||
<exclude name="**/.svn"/>
|
||||
<exclude name="vilya/tests/dist/**"/>
|
||||
<exclude name="vilya/dist/**"/>
|
||||
<exclude name="vilya/code/**"/>
|
||||
<exclude name="vilya/vilya-*.*"/>
|
||||
</fileset>
|
||||
</zip>
|
||||
</target>
|
||||
|
||||
<!-- creates a zipfile with our source distribution -->
|
||||
<target name="snapshot">
|
||||
<echo message="You may want to stop and run 'ant savedoc' first."/>
|
||||
<delete file="${deploy.dir}/${lib.name}-snapshot.zip"/>
|
||||
<mkdir dir="${deploy.dir}/snapshot/${lib.name}"/>
|
||||
<copy todir="${deploy.dir}/snapshot/${lib.name}">
|
||||
<fileset dir=".">
|
||||
<include name="**"/>
|
||||
<exclude name="dist/**"/>
|
||||
<exclude name="tests/dist/**"/>
|
||||
<exclude name="${lib.name}-*.zip"/>
|
||||
</fileset>
|
||||
</copy>
|
||||
<copy todir="${deploy.dir}/snapshot/${lib.name}/lib">
|
||||
<fileset dir="${deploy.dir}/lib" includes="*.jar"/>
|
||||
</copy>
|
||||
<copy todir="${deploy.dir}/snapshot/${lib.name}/docs/api">
|
||||
<fileset dir="${deploy.dir}/docs" includes="**"/>
|
||||
</copy>
|
||||
<zip destfile="${deploy.dir}/${lib.name}-snapshot.zip" basedir="${deploy.dir}/snapshot"/>
|
||||
<delete dir="${deploy.dir}/snapshot"/>
|
||||
</target>
|
||||
|
||||
</project>
|
||||
|
||||
Reference in New Issue
Block a user