gecko-dev/js/rhino/build.xml

133 lines
4.0 KiB
XML
Raw Normal View History

<?xml version="1.0" encoding="utf-8"?>
<!--
Build file for Rhino using Ant (see http://jakarta.apache.org/ant/index.html)
Requires Ant version 1.2
-->
2001-04-24 21:06:34 +00:00
<project name="Rhino" default="default" basedir=".">
<target name="properties">
<property name="name" value="rhino"/>
<property name="Name" value="Rhino"/>
<property name="version" value="1_5R2pre"/>
<property name="rhino.jar" value="js.jar"/>
<property name="build.compiler" value="classic"/>
<property name="debug" value="off"/>
<property name="src.dir" value="src"/>
<property name="toolsrc.dir" value="toolsrc"/>
<property name="src.examples" value="examples"/>
<property name="build.dir" value="./build"/>
<property name="build.dest" value="${build.dir}/classes"/>
<property name="dist.name" value="rhino${version}"/>
<property name="dist.dir" value="${build.dir}/${dist.name}"/>
<property name="dist.src" value="${dist.dir}/src"/>
<property name="dist.toolsrc" value="${dist.dir}/toolsrc"/>
<property name="dist.examples" value="${dist.dir}/examples"/>
<property name="dist.docs" value="${dist.dir}/docs"/>
<property name="dist.apidocs" value="${dist.docs}/apidocs"/>
<property name="dist.file" value="rhino${version}.zip"/>
<property file="apiClasses.properties"/>
<property name="docsrc.dir" value="docs"/>
<property name="dist.docsrc.dir" value="${src.dir}/docs"/>
</target>
<target name="init" depends="properties">
</target>
<target name="prepare" depends="init">
<mkdir dir="${build.dir}"/>
<mkdir dir="${build.dest}"/>
<mkdir dir="${dist.dir}"/>
<mkdir dir="${dist.src}"/>
<mkdir dir="${dist.toolsrc}"/>
<mkdir dir="${dist.examples}"/>
<mkdir dir="${dist.docs}"/>
<mkdir dir="${dist.apidocs}"/>
</target>
<target name="compile-src" depends="prepare">
<ant dir="${src.dir}"/>
</target>
<target name="compile-toolsrc" depends="prepare">
<ant dir="${toolsrc.dir}"/>
</target>
<target name="compile" depends="compile-src,compile-toolsrc"/>
<target name="jar" depends="compile">
<jar jarfile="${dist.dir}/${rhino.jar}"
basedir="${build.dest}"
manifest="${src.dir}/manifest" />
</target>
2001-04-24 21:06:34 +00:00
<target name="jar-src" depends="compile-src">
<jar jarfile="${dist.dir}/${rhino.jar}"
basedir="${build.dest}"
manifest="${src.dir}/manifest" />
</target>
<target name="copy-examples" depends="prepare">
<copy todir="${dist.examples}">
<fileset dir="${src.examples}" includes="*.java,*.js,*.html" />
</copy>
</target>
<target name="copy-misc" depends="prepare">
<tstamp/>
<filter token="datestamp" value="${TODAY}"/>
<copy todir="${dist.dir}" filtering="yes">
<fileset dir=".">
<patternset>
<include name="build.xml"/>
<include name="apiClasses.properties"/>
<include name="build-date"/>
</patternset>
</fileset>
</copy>
</target>
<target name="copy-all" depends="copy-examples,copy-misc">
</target>
<target name="copy-docs" depends="prepare">
<echo message="copy from ${docsrc.dir}"/>
<copy todir="${dist.docs}">
<fileset dir="${docsrc.dir}"
includes="**/*.html,**/*.jpg,**/*.gif" />
</copy>
</target>
<target name="javadoc" depends="compile,copy-docs">
<javadoc sourcefiles="${apiClasses}"
2001-04-25 00:24:18 +00:00
sourcepath="${src.dir}"
destdir="${dist.apidocs}"
overview="${dist.docs}/api.html"
version="true"
author="true"
public="true"
2001-04-25 17:11:34 +00:00
windowtitle="${Name}" />
</target>
2001-04-25 00:24:18 +00:00
<target name="dist" depends="copy-all,javadoc,jar">
<delete file="${dist.file}" />
<zip zipfile="${dist.file}"
basedir="${build.dir}"
includes="**"
excludes="classes/**" />
</target>
2001-04-24 21:06:34 +00:00
<target name="default">
2001-04-25 00:24:18 +00:00
<echo>
**** Building core only; for full distribution build, try "ant dist".
</echo>
2001-04-24 21:06:34 +00:00
<antcall target="jar-src"/>
</target>
</project>