Xml文件  |  65行  |  2.5 KB

<?xml version="1.0"?>
<project name="dexmaker" default="jar">

    <target name="compile">
        <mkdir dir="build/dx/classes"/>
        <javac srcdir="src/dx/java" includes="**" destdir="build/dx/classes"
               debug="on" source="1.5" target="1.5" includeantruntime="false">
            <compilerarg value="-Xlint"/>
        </javac>
        <mkdir dir="build/main/classes"/>
        <javac srcdir="src/main/java" includes="**" destdir="build/main/classes"
               debug="on" source="1.5" target="1.5" includeantruntime="false">
            <compilerarg value="-Xlint"/>
            <classpath>
                <pathelement location="build/dx/classes" />
                <pathelement location="lib/mockito-core-1.9.1-SNAPSHOT.jar" />
            </classpath>
        </javac>
        <mkdir dir="build/mockito/classes"/>
        <javac srcdir="src/mockito/java" includes="**" destdir="build/mockito/classes"
               debug="on" source="1.5" target="1.5" includeantruntime="false">
            <compilerarg value="-Xlint"/>
            <classpath>
                <pathelement location="build/main/classes" />
                <pathelement location="lib/mockito-core-1.9.1-SNAPSHOT.jar" />
            </classpath>
        </javac>
        <mkdir dir="build/test/classes"/>
        <javac srcdir="src/test/java" includes="**" destdir="build/test/classes"
               debug="on" source="1.5" target="1.5" includeantruntime="false">
            <compilerarg value="-Xlint"/>
            <classpath>
                <pathelement location="build/main/classes" />
                <pathelement location="lib/junit.jar" />
            </classpath>
        </javac>
    </target>

    <target name="jar" depends="compile">
        <taskdef name="jarjar" classname="com.tonicsystems.jarjar.JarJarTask"
            classpath="lib/jarjar.jar"/>
        <jarjar jarfile="build/dexmaker.jar">
            <fileset dir="build/dx/classes"/>
            <fileset dir="build/main/classes"/>
            <fileset dir="build/mockito/classes"/>
            <fileset dir="src/mockito/resources"/>
            <rule pattern="com.android.dx.**" result="com.google.dexmaker.dx.@1"/>
        </jarjar>
    </target>

    <target name="docs">
        <mkdir dir="build/api"/>
		<javadoc destdir="build/api" windowtitle="dexmaker" source="1.5">
			<packageset dir="src/main/java"/>
            <link href="http://download.oracle.com/javase/6/docs/api/"/>
		</javadoc>
	</target>

    <target name="clean">
        <delete dir="build"/>
    </target>

</project>