зеркало из https://github.com/mozilla/pjs.git
132 строки
3.9 KiB
XML
132 строки
3.9 KiB
XML
<?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 or later
|
|
-->
|
|
<project name="Rhino" default="default" basedir=".">
|
|
|
|
<target name="properties">
|
|
<property name="name" value="rhino"/>
|
|
<property name="Name" value="Rhino"/>
|
|
<property name="version" value="1_5R4pre"/>
|
|
<property name="rhino.jar" value="js.jar"/>
|
|
|
|
<property name="debug" value="on"/>
|
|
|
|
<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>
|
|
|
|
<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}"
|
|
sourcepath="${src.dir}"
|
|
destdir="${dist.apidocs}"
|
|
overview="${dist.docs}/api.html"
|
|
version="true"
|
|
author="true"
|
|
public="true"
|
|
windowtitle="${Name}" />
|
|
</target>
|
|
|
|
<target name="dist" depends="copy-all,javadoc,jar">
|
|
<delete file="${dist.file}" />
|
|
<zip zipfile="${dist.file}"
|
|
basedir="${build.dir}"
|
|
includes="**"
|
|
excludes="classes/**" />
|
|
</target>
|
|
|
|
<target name="default">
|
|
<echo>
|
|
**** Building core only; for full distribution build, try "ant dist".
|
|
</echo>
|
|
<antcall target="jar-src"/>
|
|
</target>
|
|
|
|
</project>
|