blob: 87483f1f2b1d66ed1ba406e41a147ece32b6e910 [file] [log] [blame]
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (C) 2014 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<project name="jill" default="dist">
<import file="../jack/build.xml"/>
<target name="dist" depends="jill, jillunittests"/>
<target name="clean" depends="jill-clean, jillunittests-clean,
asm4-clean" />
<dirname property="jill-project.dir" file="${ant.file.jill}"/>
<property name="jill.dir" value="${jill-project.dir}/jill" />
<property name="asm4.dir" value="${jill-project.dir}/asm4" />
<!-- ******************* -->
<!-- jill -->
<!-- ******************* -->
<property name="jill.build.dir" value="${jill.dir}/build/jill" />
<property name="jill.libs.dir" value="${jill.dir}/libs" />
<property name="jill.build.outdir" value="${jill.build.dir}/classes" />
<property name="jill.dist.dir" value="${jill.dir}/dist" />
<property name="jill.execname" value="jill.jar" />
<target name="jill-clean">
<delete dir="${jill.build.dir}" />
<delete dir="${jill.dist.dir}" />
<delete dir="${jill.libs.dir}" />
</target>
<target name="jill-copy-libs" depends="sched-lib,guava-lib,asm4-lib,args4j-lib,jsr305-lib,
dexcomparator-lib">
<copy todir="${jill.libs.dir}" flatten="true">
<filelist id="jill.libs.filelist" dir="/" >
<file name="${schedlib.dist.dir}/${schedlib.libname}"/>
<file name="${guava.dist.dir}/${guava.libname}"/>
<file name="${args4j.dist.dir}/${args4j.libname}"/>
<file name="${jsr305.dist.dir}/${jsr305.libname}"/>
<file name="${asm4.dist.dir}/${asm4.libname}"/>
<file name="${dexcomparator.dist.dir}/${dexcomparator.libname}"/>
</filelist>
</copy>
</target>
<target name="jill" depends="jill-copy-libs">
<!-- project layout -->
<mkdir dir="${jill.build.outdir}"/>
<mkdir dir="${jill.dist.dir}"/>
<!-- compile -->
<javac srcdir="${jill.dir}/src"
destdir="${jill.build.outdir}"
source="1.5" target="1.5"
debug="true" includeantruntime="false">
<classpath>
<fileset dir="${jill.libs.dir}">
<include name="**/*.jar"/>
</fileset>
</classpath>
</javac>
<!-- package -->
<copy todir="${jill.build.outdir}">
<fileset dir="${jill.dir}/rsc">
<include name="**/*" />
</fileset>
<fileset dir="${guava.build.outdir}">
<include name="**/*" />
</fileset>
<fileset dir="${schedlib.build.outdir}">
<include name="**/*" />
</fileset>
<fileset dir="${args4j.build.outdir}">
<include name="**/*" />
</fileset>
<fileset dir="${jsr305.build.outdir}">
<include name="**/*" />
</fileset>
<fileset dir="${asm4.build.outdir}">
<include name="**/*" />
</fileset>
</copy>
<jar destfile="${jill.dist.dir}/${jill.execname}"
manifest="${jill.dir}/etc/manifest.txt"
basedir="${jill.build.outdir}"
includes="**"/>
</target>
<!-- ******************* -->
<!-- jillunittests -->
<!-- ******************* -->
<property name="jillunittests.build.dir" value="${jill.dir}/build/jillunittests" />
<property name="jillunittests.build.outdir" value="${jillunittests.build.dir}/classes" />
<property name="jillunittests.execname" value="jillunittests.jar" />
<target name="jillunittests-clean">
<delete dir="${jillunittests.build.dir}" />
<delete dir="${jill.dist.dir}/${jillunittests.execname}" />
</target>
<target name="jillunittests" depends="jill, jackunittests">
<!-- project layout -->
<mkdir dir="${jillunittests.build.outdir}"/>
<!-- compile -->
<javac srcdir="${jill.dir}/tests"
destdir="${jillunittests.build.outdir}"
source="1.5" target="1.5"
debug="true" includeantruntime="false">
<classpath>
<filelist dir="/">
<file name="${jill.dist.dir}/${jill.execname}" />
<file name="${jackunittests.dist.dir}/${jackunittests.execname}" />
</filelist>
</classpath>
</javac>
<!-- package -->
<copy todir="${jillunittests.build.outdir}">
<fileset dir="${jill.build.outdir}">
<include name="**/*" />
</fileset>
<filelist dir="/">
<file name="${jackunittests.dist.dir}/${jackunittests.execname}" />
</filelist>
</copy>
<jar destfile="${jill.dist.dir}/${jillunittests.execname}"
basedir="${jillunittests.build.outdir}"
includes="**"/>
</target>
<!-- ******************* -->
<!-- asm4 -->
<!-- ******************* -->
<property name="asm4.build.dir" value="${asm4.dir}/build" />
<property name="asm4.build.outdir" value="${asm4.build.dir}/classes" />
<property name="asm4.dist.dir" value="${asm4.dir}/dist" />
<property name="asm4.libname" value="asm4-lib.jar" />
<target name="asm4-clean">
<delete dir="${asm4.build.dir}" />
<delete dir="${asm4.dist.dir}" />
</target>
<target name="asm4-lib">
<!-- project layout -->
<mkdir dir="${asm4.build.outdir}"/>
<mkdir dir="${asm4.dist.dir}"/>
<!-- compile -->
<javac srcdir="${asm4.dir}/src"
destdir="${asm4.build.outdir}"
source="1.5" target="1.5"
debug="true" includeantruntime="false"/>
<!-- package -->
<jar destfile="${asm4.dist.dir}/${asm4.libname}"
basedir="${asm4.build.outdir}"
includes="**"/>
</target>
</project>