2008-10-28 18:59:01 +08:00
<?xml version="1.0" encoding="UTF-8"?>
2005-10-13 21:57:02 +08:00
2008-05-07 21:17:46 +08:00
<project name= "sabbus" default= "build" >
2005-12-19 21:49:03 +08:00
<description >
2008-05-07 21:17:46 +08:00
SuperSabbus for Scala core, builds the scala library and compiler. It can also package it as a simple distribution, tests it for stable bootstrapping and against the Scala test suite. Use PackSabbus to package it for different install management tools such as Sbaz.
2005-12-19 21:49:03 +08:00
</description>
2006-03-02 22:01:45 +08:00
2008-05-07 21:17:46 +08:00
<!-- ===========================================================================
END-USER TARGETS
============================================================================ -->
<target name= "build" depends= "pack.done"
description="Builds the Scala compiler and library. Executables are in 'build/pack/bin'."/>
<target name= "clean" depends= "quick.clean"
description="Removes binaries of compiler and library. Distributions are untouched."/>
<target name= "test" depends= "test.done"
description="Runs test suite and bootstrapping test on Scala compiler and library."/>
2008-11-20 19:07:10 +08:00
<target name= "optimised.test" depends= "optimised.test.done"
description="Runs test suite and bootstrapping test on the optimised Scala compiler and library."/>
2008-05-07 21:17:46 +08:00
<target name= "docs" depends= "docs.done"
description="Builds documentation for the Scala library. Scaladoc is in 'build/scaladoc/library'."/>
<target name= "docscomp" depends= "docs.comp"
description="Builds documentation for the Scala compiler and library. Scaladoc is in 'build/scaladoc'."/>
<target name= "docsclean" depends= "docs.clean"
description="Removes generated documentation. Distributions are untouched."/>
<target name= "dist"
description="Makes a new distribution and tests it. Will remove existing binaries and documentation.">
<antcall target= "locker.clean" />
<antcall target= "docs.clean" />
<antcall target= "all.done" />
</target>
2008-05-09 23:47:25 +08:00
<target name= "fastdist" depends= "dist.done"
description="Makes a new distribution without testing it or removing partially build elements"/>
2008-05-07 21:17:46 +08:00
<target name= "distclean" depends= "dist.clean"
description="Removes all distributions. Binaries and documentation are untouched."/>
<target name= "newstarr"
description="Replaces the Starr compiler and library by one built from current sources and tests it.">
2008-09-03 03:31:24 +08:00
<fail message= "This target is not available on Windows. Use 'ant newstarrwin' instead." >
<condition >
<os family= "windows" />
</condition>
</fail>
2008-05-07 21:17:46 +08:00
<antcall target= "locker.clean" />
2008-09-03 03:31:24 +08:00
<antcall target= "pack.done" />
<antcall target= "starr.done" />
<antcall target= "locker.clean" />
<antcall target= "test.done" />
</target>
<!-- Ant on Windows is not able to delete jar files that are referenced in any <path>.
See ticket 1290 on trac. -->
<target name= "newstarrwin"
2008-10-28 18:59:01 +08:00
description="Creates a new Starr on Windows. Manually execute 'ant locker.clean build' first!">
2008-09-03 03:31:24 +08:00
<fail message= "This target is only available on Windows. Use 'ant newstarr' instead." >
<condition >
<not > <os family= "windows" /> </not>
</condition>
</fail>
<echo message= "CAUTION: Make sure to execute 'ant locker.clean build' prior to calling 'newstarrwin'." />
2008-05-07 21:17:46 +08:00
<antcall target= "starr.done" />
<antcall target= "locker.clean" />
<antcall target= "test.done" />
</target>
<target name= "freshlocker"
description="Replaces the Locker compiler and library by one built from current sources.">
<antcall target= "locker.clean" />
<antcall target= "locker.done" />
</target>
<target name= "newlocker"
description="Unlocks the Locker compiler and library and lets them be updated by Scalac.">
<antcall target= "locker.unlock" />
<antcall target= "locker.done" />
</target>
2008-10-24 21:53:46 +08:00
<target name= "optimised"
description="Build the compiler and standard library using optimisations, running 'quick'">
2008-10-30 21:23:59 +08:00
<antcall target= "optimised.bin" />
2008-10-24 21:53:46 +08:00
</target>
2008-05-07 21:17:46 +08:00
2005-12-24 02:17:24 +08:00
<!-- ===========================================================================
PROPERTIES
============================================================================ -->
2006-03-02 22:01:45 +08:00
2005-12-19 21:49:03 +08:00
<property environment= "env" />
<!-- Prevents system classpath from being used -->
<property name= "build.sysclasspath" value= "ignore" />
2006-05-11 23:29:25 +08:00
<!-- Defines the repository layout -->
2005-12-19 21:49:03 +08:00
<property name= "docs.dir" value= "${basedir}/docs" />
<property name= "lib.dir" value= "${basedir}/lib" />
2008-05-07 21:17:46 +08:00
<property name= "lib-ant.dir" value= "${lib.dir}/ant" />
2005-12-19 21:49:03 +08:00
<property name= "src.dir" value= "${basedir}/src" />
<property name= "test.dir" value= "${basedir}/test" />
2008-06-11 18:31:45 +08:00
2006-05-11 23:29:25 +08:00
<!-- Loads custom properties definitions -->
2008-05-07 21:17:46 +08:00
<property file= "${basedir}/build.properties" />
2008-01-18 21:42:10 +08:00
2008-06-10 23:07:11 +08:00
<!-- Additional command line arguments for scalac. They are added to all build targets -->
<property name= "scalac.args" value= "" />
2008-06-10 23:18:56 +08:00
<property name= "javac.args" value= "" />
2008-06-11 18:31:45 +08:00
2006-05-11 23:29:25 +08:00
<!-- Sets location of pre - compiled libraries -->
<property name= "lib.starr.jar" value= "${lib.dir}/scala-library.jar" />
<property name= "comp.starr.jar" value= "${lib.dir}/scala-compiler.jar" />
<property name= "fjbg.jar" value= "${lib.dir}/fjbg.jar" />
2007-02-07 00:06:34 +08:00
<property name= "msil.jar" value= "${lib.dir}/msil.jar" />
2007-07-17 19:31:53 +08:00
<property name= "jline.jar" value= "${lib.dir}/jline.jar" />
2008-05-07 21:17:46 +08:00
<property name= "ant.jar" value= "${ant.home}/lib/ant.jar" />
2007-07-17 19:31:53 +08:00
2006-05-11 23:29:25 +08:00
<!-- Sets location of build folders -->
2005-12-20 01:17:19 +08:00
<property name= "build.dir" value= "${basedir}/build" />
2008-05-07 21:17:46 +08:00
<property name= "build-locker.dir" value= "${build.dir}/locker" />
<property name= "build-quick.dir" value= "${build.dir}/quick" />
2008-10-24 21:53:46 +08:00
<property name= "build-optimised.dir" value= "${build.dir}/optimised" />
2008-05-07 21:17:46 +08:00
<property name= "build-pack.dir" value= "${build.dir}/pack" />
<property name= "build-strap.dir" value= "${build.dir}/strap" />
<property name= "build-docs.dir" value= "${build.dir}/scaladoc" />
2008-06-09 21:11:17 +08:00
2008-05-07 21:17:46 +08:00
<property name= "dists.dir" value= "${basedir}/dists" />
<property name= "copyright.string" value= "Copyright 2002-2008, LAMP/EPFL" />
2008-08-19 22:29:45 +08:00
<!-- These are NOT the flags used to run SuperSabbus, but the ones written
into the script runners created with scala.tools.ant.ScalaTool -->
2008-05-07 21:17:46 +08:00
<property name= "java.flags" value= "-Xmx256M -Xms32M" />
2007-04-03 19:13:36 +08:00
2008-10-30 23:04:59 +08:00
<property
name="scalacfork.jvmargs"
value="-Xms512M -Xmx512M -Xss1M -XX:MaxPermSize=128M"/>
2008-08-19 22:29:45 +08:00
2008-10-22 03:04:52 +08:00
<property name= "javac.cmd" value= "${env.JAVA_HOME}/bin/javac" />
2007-05-02 00:18:11 +08:00
<!-- ===========================================================================
INITIALISATION
============================================================================ -->
2008-05-07 21:17:46 +08:00
<target name= "init" >
<!-- Setting - up Ant contrib tasks -->
2008-05-16 20:21:35 +08:00
<taskdef resource= "net/sf/antcontrib/antlib.xml" classpath= "${lib.dir}/ant/ant-contrib.jar" />
2006-05-11 23:29:25 +08:00
<!-- This is the start time for the distribution -->
<tstamp prefix= "time" >
2008-05-07 21:17:46 +08:00
<format property= "human" pattern= "d MMMM yyyy, HH:mm:ss" />
2008-02-19 18:26:48 +08:00
<format property= "short" pattern= "yyyyMMddHHmmss" />
2006-05-11 23:29:25 +08:00
</tstamp>
2008-05-07 21:17:46 +08:00
<!-- Find out whether we are running on Windows -->
<condition property= "os.win" >
<os family= "windows" />
2007-01-31 22:31:04 +08:00
</condition>
2008-09-05 15:40:11 +08:00
<!-- Finding out SVN revision -->
2008-09-05 15:53:59 +08:00
<exec executable= "svn" outputproperty= "svn.out"
failifexecutionfails="false">
2007-03-28 17:26:13 +08:00
<arg line= " info ${basedir}" />
2008-09-05 15:40:11 +08:00
</exec>
2007-02-01 01:38:08 +08:00
<propertyregex
2007-03-28 17:26:13 +08:00
property="svn.number" input="${svn.out}" select="\1"
regexp="Revision: ([0-9]+)"
2008-05-07 21:17:46 +08:00
defaultValue="0"/>
2006-03-09 23:16:53 +08:00
<property name= "init.avail" value= "yes" />
2006-05-11 23:29:25 +08:00
<!-- Generating version number -->
2008-05-07 21:17:46 +08:00
<property file= "${basedir}/build.number" />
2006-03-06 22:12:09 +08:00
<property
2006-03-09 23:16:53 +08:00
name="version.number"
2008-02-19 18:26:48 +08:00
value="${version.major}.${version.minor}.${version.patch}.r${svn.number}-b${time.short}"/>
2006-05-11 23:29:25 +08:00
<!-- And print - out what we are building -->
<echo level= "info" message= "Build number is '${version.number}'" />
2008-09-18 15:29:03 +08:00
<echo level= "info" message= "Built ${time.human} from revision ${svn.number} with ${java.vm.name} ${java.version}" />
2008-05-07 21:17:46 +08:00
<!-- Define tasks that can be run with Starr -->
<path id= "starr.classpath" >
<pathelement location= "${lib.starr.jar}" />
<pathelement location= "${comp.starr.jar}" />
2006-05-11 23:29:25 +08:00
<pathelement location= "${fjbg.jar}" />
2008-05-07 21:17:46 +08:00
<pathelement location= "${ant.jar}" />
2006-05-11 23:29:25 +08:00
</path>
2008-05-07 21:17:46 +08:00
<taskdef resource= "scala/tools/ant/sabbus/antlib.xml" classpathref= "starr.classpath" />
2005-12-19 21:49:03 +08:00
</target>
2005-12-24 02:17:24 +08:00
<!-- ===========================================================================
2008-05-07 21:17:46 +08:00
LOCAL REFERENCE BUILD (LOCKER)
2005-12-24 02:17:24 +08:00
============================================================================ -->
2006-01-21 00:15:13 +08:00
2008-05-07 21:17:46 +08:00
<target name= "locker.start" depends= "init" >
<condition property= "locker.available" >
<available file= "${build-locker.dir}/all.complete" />
</condition>
</target>
<target name= "locker.pre-lib" depends= "locker.start" unless= "locker.available" >
<condition property= "locker.lib.needed" >
<not > <available file= "${build-locker.dir}/library.complete" /> </not>
</condition>
</target>
2006-03-02 22:01:45 +08:00
2008-05-07 21:17:46 +08:00
<target name= "locker.lib" depends= "locker.pre-lib" if= "locker.lib.needed" >
<stopwatch name= "locker.lib.timer" />
<mkdir dir= "${build-locker.dir}/classes/library" />
2006-04-10 19:02:41 +08:00
<javac
2008-04-07 21:06:24 +08:00
srcdir="${src.dir}/library"
2008-05-07 21:17:46 +08:00
destdir="${build-locker.dir}/classes/library"
classpath="${build-locker.dir}/classes/library"
includes="**/*.java"
2008-06-10 23:18:56 +08:00
target="1.5" source="1.5">
2008-08-19 22:29:45 +08:00
<compilerarg line= "${javac.args}" />
2008-06-11 18:31:45 +08:00
</javac>
2008-08-19 22:29:45 +08:00
<scalacfork
2008-05-07 21:17:46 +08:00
destdir="${build-locker.dir}/classes/library"
compilerpathref="starr.classpath"
srcpath="${src.dir}/library"
2008-08-19 22:29:45 +08:00
params="${scalac.args}"
srcdir="${src.dir}/library"
2008-10-30 23:04:59 +08:00
jvmargs="${scalacfork.jvmargs}">
2008-08-19 22:29:45 +08:00
<include name= "scala/Predef.scala" />
2008-05-07 21:17:46 +08:00
<compilationpath >
2008-08-19 22:29:45 +08:00
<pathelement location= "${build-locker.dir}/classes/library" />
2008-05-07 21:17:46 +08:00
</compilationpath>
2008-08-19 22:29:45 +08:00
</scalacfork>
<scalacfork
destdir="${build-locker.dir}/classes/library"
compilerpathref="starr.classpath"
srcpath="${src.dir}/library"
params="${scalac.args}"
srcdir="${src.dir}/library"
2008-10-30 23:04:59 +08:00
jvmargs="${scalacfork.jvmargs}">
2005-12-19 21:49:03 +08:00
<include name= "**/*.scala" />
<exclude name= "scala/Predef.scala" />
2008-08-19 22:29:45 +08:00
<compilationpath >
<pathelement location= "${build-locker.dir}/classes/library" />
</compilationpath>
</scalacfork>
2008-05-07 21:17:46 +08:00
<propertyfile file= "${build-locker.dir}/classes/library/library.properties" >
<entry key= "version.number" value= "${version.number}" />
<entry key= "copyright.string" value= "${copyright.string}" />
</propertyfile>
<copy todir= "${build-locker.dir}/classes/library" >
<fileset dir= "${src.dir}/library" >
<include name= "**/*.tmpl" />
<include name= "**/*.xml" />
<include name= "**/*.js" />
<include name= "**/*.css" />
</fileset>
</copy>
<touch file= "${build-locker.dir}/library.complete" verbose= "no" />
<stopwatch name= "locker.lib.timer" action= "total" />
</target>
<target name= "locker.pre-comp" depends= "locker.lib" unless= "locker.available" >
<condition property= "locker.comp.needed" >
<not > <available file= "${build-locker.dir}/compiler.complete" /> </not>
</condition>
</target>
<target name= "locker.comp" depends= "locker.pre-comp" if= "locker.comp.needed" >
<stopwatch name= "locker.comp.timer" />
<mkdir dir= "${build-locker.dir}/classes/compiler" />
2008-08-19 22:29:45 +08:00
<scalacfork
2008-05-07 21:17:46 +08:00
destdir="${build-locker.dir}/classes/compiler"
compilerpathref="starr.classpath"
srcpath="${src.dir}/compiler"
2008-08-19 22:29:45 +08:00
params="${scalac.args}"
srcdir="${src.dir}/compiler"
2008-10-30 23:04:59 +08:00
jvmargs="${scalacfork.jvmargs}">
2008-08-19 22:29:45 +08:00
<include name= "**/*.scala" />
2008-05-07 21:17:46 +08:00
<compilationpath >
2008-10-28 18:59:01 +08:00
<pathelement location= "${build-locker.dir}/classes/library" />
<pathelement location= "${build-locker.dir}/classes/compiler" />
2006-05-08 23:15:42 +08:00
<pathelement location= "${fjbg.jar}" />
2007-02-07 00:06:34 +08:00
<pathelement location= "${msil.jar}" />
2007-07-17 19:31:53 +08:00
<pathelement location= "${jline.jar}" />
2008-05-07 21:17:46 +08:00
<pathelement location= "${ant.jar}" />
</compilationpath>
2008-08-19 22:29:45 +08:00
</scalacfork>
2008-05-07 21:17:46 +08:00
<propertyfile file= "${build-locker.dir}/classes/compiler/compiler.properties" >
<entry key= "version.number" value= "${version.number}" />
<entry key= "copyright.string" value= "${copyright.string}" />
</propertyfile>
<copy todir= "${build-locker.dir}/classes/compiler" >
<fileset dir= "${src.dir}/compiler" >
<include name= "**/*.tmpl" />
<include name= "**/*.xml" />
<include name= "**/*.js" />
<include name= "**/*.css" />
</fileset>
</copy>
<touch file= "${build-locker.dir}/compiler.complete" verbose= "no" />
<stopwatch name= "locker.comp.timer" action= "total" />
</target>
<target name= "locker.done" depends= "locker.comp" >
<touch file= "${build-locker.dir}/all.complete" verbose= "no" />
<path id= "locker.classpath" >
<pathelement location= "${build-locker.dir}/classes/library" />
<pathelement location= "${build-locker.dir}/classes/compiler" />
<pathelement location= "${fjbg.jar}" />
<pathelement location= "${ant.jar}" />
</path>
</target>
<target name= "locker.clean" depends= "quick.clean" >
<delete dir= "${build-locker.dir}" includeemptydirs= "yes" quiet= "yes" failonerror= "no" />
</target>
<target name= "locker.unlock" depends= "quick.clean" >
<delete file= "${build-locker.dir}/library.complete" />
<delete file= "${build-locker.dir}/compiler.complete" />
2005-12-19 21:49:03 +08:00
</target>
2005-12-24 02:17:24 +08:00
<!-- ===========================================================================
2008-05-07 21:17:46 +08:00
QUICK BUILD (QUICK)
2005-12-24 02:17:24 +08:00
============================================================================ -->
2008-05-07 21:17:46 +08:00
<target name= "quick.start" depends= "locker.done" />
<target name= "quick.pre-lib" depends= "quick.start" >
<uptodate property= "quick.lib.available" targetfile= "${build-quick.dir}/library.complete" >
<srcfiles dir= "${src.dir}" >
<include name= "library/**" />
<include name= "dbc/**" />
<include name= "actors/**" />
2008-07-30 18:27:43 +08:00
<include name= "swing/**" />
2008-05-07 21:17:46 +08:00
</srcfiles>
</uptodate>
</target>
2006-03-02 22:01:45 +08:00
2008-05-07 21:17:46 +08:00
<target name= "quick.lib" depends= "quick.pre-lib" unless= "quick.lib.available" >
<stopwatch name= "quick.lib.timer" />
<mkdir dir= "${build-quick.dir}/classes/library" />
2006-04-10 19:02:41 +08:00
<javac
2008-04-07 21:06:24 +08:00
srcdir="${src.dir}/library"
2008-05-07 21:17:46 +08:00
destdir="${build-quick.dir}/classes/library"
classpath="${build-quick.dir}/classes/library"
includes="**/*.java"
2008-06-10 23:18:56 +08:00
target="1.5" source="1.5">
<compilerarg line= "${javac.args}" />
</javac>
2007-02-19 19:33:47 +08:00
<javac
srcdir="${src.dir}/actors"
2008-05-07 21:17:46 +08:00
destdir="${build-quick.dir}/classes/library"
classpath="${build-quick.dir}/classes/library"
includes="**/*.java"
2008-06-10 23:18:56 +08:00
target="1.5" source="1.5">
<compilerarg line= "${javac.args}" />
</javac>
2008-08-19 22:29:45 +08:00
<scalacfork
2008-05-07 21:17:46 +08:00
destdir="${build-quick.dir}/classes/library"
compilerpathref="locker.classpath"
srcpath="${src.dir}/library"
2008-08-19 22:29:45 +08:00
params="${scalac.args}"
srcdir="${src.dir}/library"
2008-10-30 23:04:59 +08:00
jvmargs="${scalacfork.jvmargs}">
2008-08-19 22:29:45 +08:00
<include name= "scala/Predef.scala" />
2008-05-07 21:17:46 +08:00
<compilationpath >
2008-10-28 18:59:01 +08:00
<pathelement location= "${build-quick.dir}/classes/library" />
2008-05-07 21:17:46 +08:00
</compilationpath>
2008-08-19 22:29:45 +08:00
</scalacfork>
<scalacfork
2008-05-07 21:17:46 +08:00
destdir="${build-quick.dir}/classes/library"
compilerpathref="locker.classpath"
srcpath="${src.dir}/library"
2008-08-19 22:29:45 +08:00
params="${scalac.args}"
srcdir="${src.dir}/library"
2008-10-30 23:04:59 +08:00
jvmargs="${scalacfork.jvmargs}">
2008-08-19 22:29:45 +08:00
<include name= "**/*.scala" />
<exclude name= "scala/Predef.scala" />
2008-05-07 21:17:46 +08:00
<compilationpath >
2008-10-28 18:59:01 +08:00
<pathelement location= "${build-quick.dir}/classes/library" />
2008-05-07 21:17:46 +08:00
</compilationpath>
2008-08-19 22:29:45 +08:00
</scalacfork>
<scalacfork
destdir="${build-quick.dir}/classes/library"
compilerpathref="locker.classpath"
srcpath="${src.dir}/library"
params="${scalac.args}"
srcdir="${src.dir}/actors"
2008-10-30 23:04:59 +08:00
jvmargs="${scalacfork.jvmargs}">
2008-05-07 21:17:46 +08:00
<include name= "**/*.scala" />
2008-08-19 22:29:45 +08:00
<compilationpath >
2008-10-28 18:59:01 +08:00
<pathelement location= "${build-quick.dir}/classes/library" />
2008-08-19 22:29:45 +08:00
</compilationpath>
</scalacfork>
<scalacfork
destdir="${build-quick.dir}/classes/library"
compilerpathref="locker.classpath"
srcpath="${src.dir}/library"
params="${scalac.args}"
srcdir="${src.dir}/dbc"
2008-10-30 23:04:59 +08:00
jvmargs="${scalacfork.jvmargs}">
2008-05-07 21:17:46 +08:00
<include name= "**/*.scala" />
2008-08-19 22:29:45 +08:00
<compilationpath >
2008-10-28 18:59:01 +08:00
<pathelement location= "${build-quick.dir}/classes/library" />
2008-08-19 22:29:45 +08:00
</compilationpath>
</scalacfork>
<scalacfork
destdir="${build-quick.dir}/classes/library"
compilerpathref="locker.classpath"
srcpath="${src.dir}/library"
params="${scalac.args}"
srcdir="${src.dir}/swing"
2008-10-30 23:04:59 +08:00
jvmargs="${scalacfork.jvmargs}">
2008-07-30 18:27:43 +08:00
<include name= "**/*.scala" />
2008-08-19 22:29:45 +08:00
<compilationpath >
2008-10-28 18:59:01 +08:00
<pathelement location= "${build-quick.dir}/classes/library" />
2008-08-19 22:29:45 +08:00
</compilationpath>
</scalacfork>
2008-05-07 21:17:46 +08:00
<propertyfile file= "${build-quick.dir}/classes/library/library.properties" >
<entry key= "version.number" value= "${version.number}" />
<entry key= "copyright.string" value= "${copyright.string}" />
</propertyfile>
<copy todir= "${build-quick.dir}/classes/library" >
<fileset dir= "${src.dir}/library" >
<include name= "**/*.tmpl" />
<include name= "**/*.xml" />
<include name= "**/*.js" />
<include name= "**/*.css" />
</fileset>
</copy>
<touch file= "${build-quick.dir}/library.complete" verbose= "no" />
<stopwatch name= "quick.lib.timer" action= "total" />
</target>
<target name= "quick.pre-comp" depends= "quick.lib" >
<uptodate property= "quick.comp.available" targetfile= "${build-quick.dir}/compiler.complete" >
<srcfiles dir= "${src.dir}/compiler" />
</uptodate>
</target>
<target name= "quick.comp" depends= "quick.pre-comp" unless= "quick.comp.available" >
<stopwatch name= "quick.comp.timer" />
<mkdir dir= "${build-quick.dir}/classes/compiler" />
2008-08-19 22:29:45 +08:00
<scalacfork
2008-05-07 21:17:46 +08:00
destdir="${build-quick.dir}/classes/compiler"
compilerpathref="locker.classpath"
srcpath="${src.dir}/compiler"
2008-08-19 22:29:45 +08:00
params="${scalac.args}"
srcdir="${src.dir}/compiler"
2008-10-30 23:04:59 +08:00
jvmargs="${scalacfork.jvmargs}">
2008-08-19 22:29:45 +08:00
<include name= "**/*.scala" />
2008-05-07 21:17:46 +08:00
<compilationpath >
2008-10-28 18:59:01 +08:00
<pathelement location= "${build-quick.dir}/classes/library" />
<pathelement location= "${build-quick.dir}/classes/compiler" />
2006-05-08 23:15:42 +08:00
<pathelement location= "${fjbg.jar}" />
2007-02-07 00:06:34 +08:00
<pathelement location= "${msil.jar}" />
2007-07-17 19:31:53 +08:00
<pathelement location= "${jline.jar}" />
2008-05-07 21:17:46 +08:00
<pathelement location= "${ant.jar}" />
</compilationpath>
2008-08-19 22:29:45 +08:00
</scalacfork>
2008-05-07 21:17:46 +08:00
<propertyfile file= "${build-quick.dir}/classes/compiler/compiler.properties" >
<entry key= "version.number" value= "${version.number}" />
<entry key= "copyright.string" value= "${copyright.string}" />
</propertyfile>
<copy todir= "${build-quick.dir}/classes/compiler" >
<fileset dir= "${src.dir}/compiler" >
<include name= "**/*.tmpl" />
<include name= "**/*.xml" />
<include name= "**/*.js" />
<include name= "**/*.css" />
</fileset>
</copy>
<touch file= "${build-quick.dir}/compiler.complete" verbose= "no" />
<stopwatch name= "quick.comp.timer" action= "total" />
</target>
<target name= "quick.pre-partest" depends= "quick.comp" >
<uptodate property= "quick.partest.available" targetfile= "${build-quick.dir}/partest.complete" >
<srcfiles dir= "${src.dir}/partest" />
</uptodate>
</target>
<target name= "quick.partest" depends= "quick.pre-partest" unless= "quick.partest.available" >
<stopwatch name= "quick.partest.timer" />
<mkdir dir= "${build-quick.dir}/classes/partest" />
2008-02-12 01:52:15 +08:00
<javac
srcdir="${src.dir}/partest"
2008-05-07 21:17:46 +08:00
destdir="${build-quick.dir}/classes/partest"
target="1.5" source="1.5">
2007-09-11 23:41:12 +08:00
<classpath >
2008-10-28 18:59:01 +08:00
<pathelement location= "${build-quick.dir}/classes/library" />
<pathelement location= "${build-quick.dir}/classes/compiler" />
<pathelement location= "${build-quick.dir}/classes/partest" />
2007-09-11 23:41:12 +08:00
</classpath>
2008-05-07 21:17:46 +08:00
<include name= "**/*.java" />
2008-06-10 23:18:56 +08:00
<compilerarg line= "${javac.args}" />
2008-05-07 21:17:46 +08:00
</javac>
2008-08-19 22:29:45 +08:00
<scalacfork
2008-05-07 21:17:46 +08:00
destdir="${build-quick.dir}/classes/partest"
compilerpathref="locker.classpath"
2008-06-09 21:11:17 +08:00
srcpath="${src.dir}/partest"
2008-08-19 22:29:45 +08:00
params="${scalac.args}"
srcdir="${src.dir}/partest"
2008-10-30 23:04:59 +08:00
jvmargs="${scalacfork.jvmargs}">
2008-08-19 22:29:45 +08:00
<include name= "**/*.scala" />
2008-05-07 21:17:46 +08:00
<compilationpath >
2008-10-28 18:59:01 +08:00
<pathelement location= "${build-quick.dir}/classes/library" />
<pathelement location= "${build-quick.dir}/classes/compiler" />
<pathelement location= "${build-quick.dir}/classes/partest" />
2008-05-07 21:17:46 +08:00
<pathelement location= "${ant.jar}" />
</compilationpath>
2008-08-19 22:29:45 +08:00
</scalacfork>
2008-05-07 21:17:46 +08:00
<copy todir= "${build-quick.dir}/classes/partest" >
<fileset dir= "${src.dir}/partest" >
<include name= "**/*.xml" />
</fileset>
</copy>
<touch file= "${build-quick.dir}/partest.complete" verbose= "no" />
<stopwatch name= "quick.partest.timer" action= "total" />
</target>
<target name= "quick.pre-bin" depends= "quick.partest" >
<condition property= "quick.bin.available" >
<isset property= "quick.comp.available" />
</condition>
</target>
<target name= "quick.bin" depends= "quick.pre-bin" unless= "quick.bin.available" >
<path id= "quick.bin.classpath" >
2008-10-28 18:59:01 +08:00
<pathelement location= "${build-quick.dir}/classes/library" />
<pathelement location= "${build-quick.dir}/classes/compiler" />
2008-05-07 21:17:46 +08:00
<pathelement location= "${fjbg.jar}" />
<pathelement location= "${jline.jar}" />
</path>
<taskdef name= "quick-bin" classname= "scala.tools.ant.ScalaTool" classpathref= "quick.bin.classpath" />
<mkdir dir= "${build-quick.dir}/bin" />
<quick-bin
file="${build-quick.dir}/bin/scala"
2006-06-15 23:43:19 +08:00
class="scala.tools.nsc.MainGenericRunner"
2008-05-07 21:17:46 +08:00
javaFlags="${java.flags}"
classpathref="quick.bin.classpath"/>
<quick-bin
file="${build-quick.dir}/bin/scalac"
2006-03-06 22:12:09 +08:00
class="scala.tools.nsc.Main"
2008-05-07 21:17:46 +08:00
javaFlags="${java.flags}"
classpathref="quick.bin.classpath"/>
<quick-bin
file="${build-quick.dir}/bin/scaladoc"
2008-03-05 19:50:24 +08:00
class="scala.tools.nsc.ScalaDoc"
2008-05-07 21:17:46 +08:00
javaFlags="${java.flags}"
classpathref="quick.bin.classpath"/>
<quick-bin
file="${build-quick.dir}/bin/fsc"
2006-06-07 00:52:36 +08:00
class="scala.tools.nsc.CompileClient"
2008-05-07 21:17:46 +08:00
javaFlags="${java.flags}"
classpathref="quick.bin.classpath"/>
<chmod perm= "ugo+rx" file= "${build-quick.dir}/bin/scala" />
<chmod perm= "ugo+rx" file= "${build-quick.dir}/bin/scalac" />
<chmod perm= "ugo+rx" file= "${build-quick.dir}/bin/scaladoc" />
<chmod perm= "ugo+rx" file= "${build-quick.dir}/bin/fsc" />
<touch file= "${build-quick.dir}/bin.complete" verbose= "no" />
2005-12-19 21:49:03 +08:00
</target>
2008-10-28 18:59:01 +08:00
2008-10-24 21:53:46 +08:00
<target name= "quick.done" depends= "quick.bin" >
<path id= "quick.classpath" >
<pathelement location= "${build-quick.dir}/classes/library" />
<pathelement location= "${build-quick.dir}/classes/compiler" />
<pathelement location= "${fjbg.jar}" />
<pathelement location= "${ant.jar}" />
</path>
</target>
2008-05-07 21:17:46 +08:00
<target name= "quick.clean" depends= "pack.clean" >
<delete dir= "${build-quick.dir}" includeemptydirs= "yes" quiet= "yes" failonerror= "no" />
2006-01-21 00:15:13 +08:00
</target>
2005-12-19 21:49:03 +08:00
2007-06-13 20:14:52 +08:00
<!-- ===========================================================================
2008-05-07 21:17:46 +08:00
PACKED QUICK BUILD (PACK)
2007-06-13 20:14:52 +08:00
============================================================================ -->
2008-05-07 21:17:46 +08:00
<target name= "pack.start" depends= "quick.done" />
<target name= "pack.pre-lib" depends= "pack.start" >
<uptodate
property="pack.lib.available"
targetfile="${build-pack.dir}/lib/scala-library.jar"
srcfile="${build-quick.dir}/library.complete"/>
2007-06-13 20:14:52 +08:00
</target>
2008-05-07 21:17:46 +08:00
<target name= "pack.lib" depends= "pack.pre-lib" unless= "pack.lib.available" >
<mkdir dir= "${build-pack.dir}/lib" />
<jar destfile= "${build-pack.dir}/lib/scala-library.jar" >
<fileset dir= "${build-quick.dir}/classes/library" >
<exclude name= "scala/dbc/**" />
2008-07-30 18:27:43 +08:00
<exclude name= "scala/swing/**" />
2008-05-07 21:17:46 +08:00
</fileset>
2007-11-21 02:35:24 +08:00
</jar>
2008-05-07 21:17:46 +08:00
<jar destfile= "${build-pack.dir}/lib/scala-dbc.jar" >
<fileset dir= "${build-quick.dir}/classes/library" >
<include name= "scala/dbc/**" />
</fileset>
2007-11-21 02:35:24 +08:00
</jar>
2008-07-30 18:27:43 +08:00
<jar destfile= "${build-pack.dir}/lib/scala-swing.jar" >
<fileset dir= "${build-quick.dir}/classes/library" >
<include name= "scala/swing/**" />
</fileset>
<fileset dir= "${src.dir}/swing" >
<include name= "scala/swing/test/images/**" />
</fileset>
</jar>
2007-06-13 20:14:52 +08:00
</target>
2008-05-18 20:53:20 +08:00
2008-06-09 21:11:17 +08:00
<target name= "pack.pre-comp" depends= "pack.lib" >
2008-05-07 21:17:46 +08:00
<uptodate
property="pack.comp.available"
targetfile="${build-pack.dir}/lib/scala-compiler.jar"
srcfile="${build-quick.dir}/compiler.complete"/>
2008-02-20 01:57:34 +08:00
</target>
2007-02-10 01:09:49 +08:00
2008-05-07 21:17:46 +08:00
<target name= "pack.comp" depends= "pack.pre-comp" unless= "pack.comp.available" >
2008-05-18 20:53:20 +08:00
<mkdir dir= "${build-pack.dir}/META-INF" />
<copy file= "META-INF/MANIFEST.MF" toDir= "${build-pack.dir}/META-INF" />
<manifest file= "${build-pack.dir}/META-INF/MANIFEST.MF" mode= "update" >
<attribute name= "Bundle-Version" value= "${version.number}" />
</manifest>
2008-10-28 18:59:01 +08:00
<mkdir dir= "${build-pack.dir}/lib" />
2008-05-18 20:53:20 +08:00
<jar destfile= "${build-pack.dir}/lib/scala-compiler.jar" manifest= "${build-pack.dir}/META-INF/MANIFEST.MF" >
2008-05-07 21:17:46 +08:00
<fileset dir= "${build-quick.dir}/classes/compiler" />
2008-09-05 15:40:11 +08:00
<!-- filemode / dirmode: see trac ticket #1294 -->
<zipfileset dirmode= "755" filemode= "644" src= "${fjbg.jar}" />
<zipfileset dirmode= "755" filemode= "644" src= "${msil.jar}" />
<zipfileset dirmode= "755" filemode= "644" src= "${jline.jar}" />
2008-05-07 21:17:46 +08:00
</jar>
2007-02-10 01:09:49 +08:00
</target>
2008-05-07 21:17:46 +08:00
<target name= "pack.pre-partest" depends= "pack.comp" >
<uptodate
property="pack.partest.available"
targetfile="${build-pack.dir}/lib/scala-partest.jar"
srcfile="${build-quick.dir}/partest.complete"/>
2007-02-10 01:09:49 +08:00
</target>
2008-05-07 21:17:46 +08:00
<target name= "pack.partest" depends= "pack.pre-partest" unless= "pack.partest.available" >
<mkdir dir= "${build-pack.dir}/lib" />
<jar destfile= "${build-pack.dir}/lib/scala-partest.jar" >
<fileset dir= "${build-quick.dir}/classes/partest" />
</jar>
2007-06-18 16:26:33 +08:00
</target>
2008-05-07 21:17:46 +08:00
<target name= "pack.pre-bin" depends= "pack.partest" >
<uptodate
property="pack.bin.available"
srcfile="${build-pack.dir}/lib/scala-compiler.jar"
targetfile="${build-pack.dir}/bin.complete"/>
</target>
2007-11-23 01:16:07 +08:00
2008-05-07 21:17:46 +08:00
<target name= "pack.bin" depends= "pack.pre-bin" unless= "pack.bin.available" >
<taskdef name= "pack-bin" classname= "scala.tools.ant.ScalaTool" >
2007-11-23 01:16:07 +08:00
<classpath >
2008-10-28 18:59:01 +08:00
<pathelement location= "${build-pack.dir}/lib/scala-library.jar" />
<pathelement location= "${build-pack.dir}/lib/scala-compiler.jar" />
2007-11-23 01:16:07 +08:00
</classpath>
2008-05-07 21:17:46 +08:00
</taskdef>
<mkdir dir= "${build-pack.dir}/bin" />
<pack-bin
file="${build-pack.dir}/bin/scala"
2007-11-23 01:16:07 +08:00
class="scala.tools.nsc.MainGenericRunner"
javaFlags="${java.flags}"/>
2008-05-07 21:17:46 +08:00
<pack-bin
file="${build-pack.dir}/bin/scalac"
2007-11-23 01:16:07 +08:00
class="scala.tools.nsc.Main"
javaFlags="${java.flags}"/>
2008-05-07 21:17:46 +08:00
<pack-bin
file="${build-pack.dir}/bin/scaladoc"
2008-03-05 19:50:24 +08:00
class="scala.tools.nsc.ScalaDoc"
2007-11-23 01:16:07 +08:00
javaFlags="${java.flags}"/>
2008-05-07 21:17:46 +08:00
<pack-bin
file="${build-pack.dir}/bin/fsc"
2008-04-15 23:56:51 +08:00
class="scala.tools.nsc.CompileClient"
javaFlags="${java.flags}"/>
2008-05-07 21:17:46 +08:00
<chmod perm= "ugo+rx" file= "${build-pack.dir}/bin/scala" />
<chmod perm= "ugo+rx" file= "${build-pack.dir}/bin/scalac" />
<chmod perm= "ugo+rx" file= "${build-pack.dir}/bin/scaladoc" />
<chmod perm= "ugo+rx" file= "${build-pack.dir}/bin/fsc" />
<touch file= "${build-pack.dir}/bin.complete" verbose= "no" />
2007-11-23 01:16:07 +08:00
</target>
2008-05-07 21:17:46 +08:00
<target name= "pack.done" depends= "pack.bin" >
<path id= "pack.classpath" >
<pathelement location= "${build-pack.dir}/lib/scala-library.jar" />
<pathelement location= "${build-pack.dir}/lib/scala-compiler.jar" />
<pathelement location= "${build-pack.dir}/lib/scala-partest.jar" />
<pathelement location= "${ant.jar}" />
</path>
<taskdef resource= "scala/tools/ant/antlib.xml" classpathref= "pack.classpath" />
<taskdef resource= "scala/tools/partest/antlib.xml" classpathref= "pack.classpath" />
</target>
<target name= "pack.clean" depends= "strap.clean" >
<delete dir= "${build-pack.dir}" includeemptydirs= "yes" quiet= "yes" failonerror= "no" />
</target>
2005-12-24 02:17:24 +08:00
<!-- ===========================================================================
2008-05-07 21:17:46 +08:00
BOOTSTRAPPING BUILD (STRAP)
2005-12-24 02:17:24 +08:00
============================================================================ -->
2008-05-07 21:17:46 +08:00
<target name= "strap.start" depends= "pack.done" />
<target name= "strap.pre-lib" depends= "strap.start" >
<uptodate property= "strap.lib.available" targetfile= "${build-strap.dir}/library.complete" >
<srcfiles dir= "${src.dir}" >
<include name= "library/**" />
<include name= "dbc/**" />
<include name= "actors/**" />
2008-07-30 18:27:43 +08:00
<include name= "swing/**" />
2008-05-07 21:17:46 +08:00
</srcfiles>
</uptodate>
</target>
2006-03-02 22:01:45 +08:00
2008-05-07 21:17:46 +08:00
<target name= "strap.lib" depends= "strap.pre-lib" unless= "strap.lib.available" >
<stopwatch name= "strap.lib.timer" />
<mkdir dir= "${build-strap.dir}/classes/library" />
2006-04-10 19:02:41 +08:00
<javac
2006-05-11 23:29:25 +08:00
srcdir="${src.dir}/library"
2008-05-07 21:17:46 +08:00
destdir="${build-strap.dir}/classes/library"
classpath="${build-strap.dir}/classes/library"
includes="**/*.java"
2008-06-10 23:18:56 +08:00
target="1.5" source="1.5">
<compilerarg line= "${javac.args}" />
2008-06-11 18:31:45 +08:00
</javac>
2008-05-07 21:17:46 +08:00
<javac
srcdir="${src.dir}/actors"
destdir="${build-strap.dir}/classes/library"
classpath="${build-strap.dir}/classes/library"
includes="**/*.java"
2008-06-10 23:18:56 +08:00
target="1.5" source="1.5">
<compilerarg line= "${javac.args}" />
2008-06-11 18:31:45 +08:00
</javac>
2008-05-07 21:17:46 +08:00
<scalac
2006-05-11 23:29:25 +08:00
srcdir="${src.dir}/library"
2008-05-07 21:17:46 +08:00
destdir="${build-strap.dir}/classes/library"
classpath="${build-strap.dir}/classes/library"
sourcepath="${src.dir}/library"
2008-06-10 23:07:11 +08:00
target="jvm-1.5"
addparams="${scalac.args}">
2008-05-07 21:17:46 +08:00
<include name= "scala/Predef.scala" />
</scalac>
<scalac
2006-05-11 23:29:25 +08:00
srcdir="${src.dir}/library"
2008-05-07 21:17:46 +08:00
destdir="${build-strap.dir}/classes/library"
classpath="${build-strap.dir}/classes/library"
2008-06-10 23:07:11 +08:00
target="jvm-1.5"
addparams="${scalac.args}">
2005-12-19 21:49:03 +08:00
<include name= "**/*.scala" />
<exclude name= "scala/Predef.scala" />
2008-05-07 21:17:46 +08:00
</scalac>
<scalac
2006-06-21 20:35:21 +08:00
srcdir="${src.dir}/actors"
2008-05-07 21:17:46 +08:00
destdir="${build-strap.dir}/classes/library"
classpath="${build-strap.dir}/classes/library"
2008-06-10 23:07:11 +08:00
target="jvm-1.5"
addparams="${scalac.args}">
2008-05-07 21:17:46 +08:00
<include name= "**/*.scala" />
</scalac>
<scalac
srcdir="${src.dir}/dbc"
destdir="${build-strap.dir}/classes/library"
classpath="${build-strap.dir}/classes/library"
2008-06-10 23:07:11 +08:00
target="jvm-1.5"
addparams="${scalac.args}">
2008-05-07 21:17:46 +08:00
<include name= "**/*.scala" />
</scalac>
2008-07-30 18:27:43 +08:00
<scalac
srcdir="${src.dir}/swing"
destdir="${build-strap.dir}/classes/library"
classpath="${build-strap.dir}/classes/library"
target="jvm-1.5"
addparams="${scalac.args}">
<include name= "**/*.scala" />
</scalac>
2008-05-07 21:17:46 +08:00
<propertyfile file= "${build-strap.dir}/classes/library/library.properties" >
<entry key= "version.number" value= "${version.number}" />
<entry key= "copyright.string" value= "${copyright.string}" />
</propertyfile>
<copy todir= "${build-strap.dir}/classes/library" >
<fileset dir= "${src.dir}/library" >
<include name= "**/*.tmpl" />
<include name= "**/*.xml" />
<include name= "**/*.js" />
<include name= "**/*.css" />
</fileset>
</copy>
<touch file= "${build-strap.dir}/library.complete" verbose= "no" />
<stopwatch name= "strap.lib.timer" action= "total" />
</target>
<target name= "strap.pre-comp" depends= "strap.lib" >
<uptodate property= "strap.comp.available" targetfile= "${build-strap.dir}/compiler.complete" >
<srcfiles dir= "${src.dir}/compiler" />
</uptodate>
</target>
<target name= "strap.comp" depends= "strap.pre-comp" unless= "strap.comp.available" >
<stopwatch name= "strap.comp.timer" />
<mkdir dir= "${build-strap.dir}/classes/compiler" />
<scalac
2006-05-11 23:29:25 +08:00
srcdir="${src.dir}/compiler"
2008-05-07 21:17:46 +08:00
destdir="${build-strap.dir}/classes/compiler"
2008-06-10 23:07:11 +08:00
target="jvm-1.5"
addparams="${scalac.args}">
2008-05-07 21:17:46 +08:00
<include name= "**/*.scala" />
2005-12-19 21:49:03 +08:00
<classpath >
2008-05-07 21:17:46 +08:00
<pathelement location= "${build-strap.dir}/classes/library" />
<pathelement location= "${build-strap.dir}/classes/compiler" />
2006-05-08 23:15:42 +08:00
<pathelement location= "${fjbg.jar}" />
2007-02-07 00:06:34 +08:00
<pathelement location= "${msil.jar}" />
2007-07-17 19:31:53 +08:00
<pathelement location= "${jline.jar}" />
2008-05-07 21:17:46 +08:00
<pathelement location= "${ant.jar}" />
2005-12-19 21:49:03 +08:00
</classpath>
2008-05-07 21:17:46 +08:00
</scalac>
<propertyfile file= "${build-strap.dir}/classes/compiler/compiler.properties" >
<entry key= "version.number" value= "${version.number}" />
<entry key= "copyright.string" value= "${copyright.string}" />
</propertyfile>
<copy todir= "${build-strap.dir}/classes/compiler" >
<fileset dir= "${src.dir}/compiler" >
<include name= "**/*.tmpl" />
<include name= "**/*.xml" />
<include name= "**/*.js" />
<include name= "**/*.css" />
</fileset>
</copy>
<touch file= "${build-strap.dir}/compiler.complete" verbose= "no" />
<stopwatch name= "strap.comp.timer" action= "total" />
</target>
<target name= "strap.pre-partest" depends= "strap.comp" >
<uptodate property= "strap.partest.available" targetfile= "${build-strap.dir}/partest.complete" >
<srcfiles dir= "${src.dir}/partest" />
</uptodate>
</target>
<target name= "strap.partest" depends= "strap.pre-partest" unless= "strap.partest.available" >
<stopwatch name= "strap.partest.timer" />
<mkdir dir= "${build-strap.dir}/classes/partest" />
2008-02-12 18:27:50 +08:00
<javac
srcdir="${src.dir}/partest"
2008-05-07 21:17:46 +08:00
destdir="${build-strap.dir}/classes/partest"
target="1.5" source="1.5">
<classpath >
2008-10-28 18:59:01 +08:00
<pathelement location= "${build-strap.dir}/classes/library" />
<pathelement location= "${build-strap.dir}/classes/compiler" />
<pathelement location= "${build-strap.dir}/classes/partest" />
2008-05-07 21:17:46 +08:00
</classpath>
<include name= "**/*.java" />
2008-06-10 23:18:56 +08:00
<compilerarg line= "${javac.args}" />
2008-05-07 21:17:46 +08:00
</javac>
<scalac
2007-09-11 23:41:12 +08:00
srcdir="${src.dir}/partest"
2008-05-07 21:17:46 +08:00
destdir="${build-strap.dir}/classes/partest"
2008-06-10 23:07:11 +08:00
target="jvm-1.5"
addparams="${scalac.args}">
2008-05-07 21:17:46 +08:00
<include name= "**/*.scala" />
2007-09-11 23:41:12 +08:00
<classpath >
2008-05-07 21:17:46 +08:00
<pathelement location= "${build-strap.dir}/classes/library" />
<pathelement location= "${build-strap.dir}/classes/compiler" />
<pathelement location= "${build-strap.dir}/classes/partest" />
2008-03-01 00:33:25 +08:00
<pathelement location= "${ant.jar}" />
2007-09-11 23:41:12 +08:00
</classpath>
2008-05-07 21:17:46 +08:00
</scalac>
<copy todir= "${build-strap.dir}/classes/partest" >
<fileset dir= "${src.dir}/partest" >
<include name= "**/*.xml" />
2005-12-20 01:17:19 +08:00
</fileset>
2008-05-07 21:17:46 +08:00
</copy>
<touch file= "${build-strap.dir}/partest.complete" verbose= "no" />
<stopwatch name= "strap.partest.timer" action= "total" />
2005-12-19 21:49:03 +08:00
</target>
2008-05-07 21:17:46 +08:00
<target name= "strap.done" depends= "strap.partest" />
2006-03-02 22:01:45 +08:00
2008-05-07 21:17:46 +08:00
<target name= "strap.clean" >
<delete dir= "${build-strap.dir}" includeemptydirs= "yes" quiet= "yes" failonerror= "no" />
2006-01-21 00:15:13 +08:00
</target>
2005-12-19 21:49:03 +08:00
2008-10-24 21:53:46 +08:00
<!-- ===========================================================================
OPTIMISED COMPILER
============================================================================ -->
<target name= "optimised.start" depends= "quick.done" />
<target name= "optimised.pre-lib" depends= "optimised.start" >
<uptodate property= "optimised.lib.available" targetfile= "${build-optimised.dir}/library.complete" >
<srcfiles dir= "${src.dir}" >
<include name= "library/**" />
<include name= "dbc/**" />
<include name= "actors/**" />
<include name= "swing/**" />
</srcfiles>
</uptodate>
</target>
<target name= "optimised.lib" depends= "optimised.pre-lib" unless= "optimised.lib.available" >
<stopwatch name= "optimised.lib.timer" />
<mkdir dir= "${build-optimised.dir}/classes/library" />
<javac
srcdir="${src.dir}/library"
destdir="${build-optimised.dir}/classes/library"
classpath="${build-optimised.dir}/classes/library"
includes="**/*.java"
target="1.5" source="1.5">
<compilerarg line= "${javac.args}" />
</javac>
<javac
srcdir="${src.dir}/actors"
destdir="${build-optimised.dir}/classes/library"
classpath="${build-optimised.dir}/classes/library"
includes="**/*.java"
target="1.5" source="1.5">
<compilerarg line= "${javac.args}" />
</javac>
<scalacfork
destdir="${build-optimised.dir}/classes/library"
compilerpathref="quick.classpath"
srcpath="${src.dir}/library"
params="-optimise ${scalac.args}"
srcdir="${src.dir}/library"
2008-10-30 23:04:59 +08:00
jvmargs="${scalacfork.jvmargs}">
2008-10-24 21:53:46 +08:00
<include name= "scala/Predef.scala" />
<compilationpath >
2008-10-28 18:59:01 +08:00
<pathelement location= "${build-optimised.dir}/classes/library" />
2008-10-24 21:53:46 +08:00
</compilationpath>
</scalacfork>
<scalacfork
destdir="${build-optimised.dir}/classes/library"
compilerpathref="quick.classpath"
srcpath="${src.dir}/library"
params="-optimise ${scalac.args}"
srcdir="${src.dir}/library"
2008-10-30 23:04:59 +08:00
jvmargs="${scalacfork.jvmargs}">
2008-10-24 21:53:46 +08:00
<include name= "**/*.scala" />
<exclude name= "scala/Predef.scala" />
<compilationpath >
2008-10-28 18:59:01 +08:00
<pathelement location= "${build-optimised.dir}/classes/library" />
2008-10-24 21:53:46 +08:00
</compilationpath>
</scalacfork>
<scalacfork
destdir="${build-optimised.dir}/classes/library"
compilerpathref="quick.classpath"
srcpath="${src.dir}/library"
params="-optimise ${scalac.args}"
srcdir="${src.dir}/actors"
2008-10-30 23:04:59 +08:00
jvmargs="${scalacfork.jvmargs}">
2008-10-24 21:53:46 +08:00
<include name= "**/*.scala" />
<compilationpath >
2008-10-28 18:59:01 +08:00
<pathelement location= "${build-optimised.dir}/classes/library" />
2008-10-24 21:53:46 +08:00
</compilationpath>
</scalacfork>
<scalacfork
destdir="${build-optimised.dir}/classes/library"
compilerpathref="quick.classpath"
srcpath="${src.dir}/library"
params="-optimise ${scalac.args}"
srcdir="${src.dir}/dbc"
2008-10-30 23:04:59 +08:00
jvmargs="${scalacfork.jvmargs}">
2008-10-24 21:53:46 +08:00
<include name= "**/*.scala" />
<compilationpath >
2008-10-28 18:59:01 +08:00
<pathelement location= "${build-optimised.dir}/classes/library" />
2008-10-24 21:53:46 +08:00
</compilationpath>
</scalacfork>
<scalacfork
destdir="${build-optimised.dir}/classes/library"
compilerpathref="quick.classpath"
srcpath="${src.dir}/library"
params="-optimise ${scalac.args}"
srcdir="${src.dir}/swing"
2008-10-30 23:04:59 +08:00
jvmargs="${scalacfork.jvmargs}">
2008-10-24 21:53:46 +08:00
<include name= "**/*.scala" />
<compilationpath >
2008-10-28 18:59:01 +08:00
<pathelement location= "${build-optimised.dir}/classes/library" />
2008-10-24 21:53:46 +08:00
</compilationpath>
</scalacfork>
<propertyfile file= "${build-optimised.dir}/classes/library/library.properties" >
<entry key= "version.number" value= "${version.number}" />
<entry key= "copyright.string" value= "${copyright.string}" />
</propertyfile>
<copy todir= "${build-optimised.dir}/classes/library" >
<fileset dir= "${src.dir}/library" >
<include name= "**/*.tmpl" />
<include name= "**/*.xml" />
<include name= "**/*.js" />
<include name= "**/*.css" />
</fileset>
</copy>
<touch file= "${build-optimised.dir}/library.complete" verbose= "no" />
<stopwatch name= "optimised.lib.timer" action= "total" />
</target>
<target name= "optimised.pre-comp" depends= "optimised.lib" >
<uptodate property= "optimised.comp.available" targetfile= "${build-opimised.dir}/compiler.complete" >
<srcfiles dir= "${src.dir}/compiler" />
</uptodate>
</target>
<target name= "optimised.comp" depends= "optimised.pre-comp" unless= "optimised.comp.available" >
<stopwatch name= "optimised.comp.timer" />
<mkdir dir= "${build-optimised.dir}/classes/compiler" />
<scalacfork
destdir="${build-optimised.dir}/classes/compiler"
compilerpathref="quick.classpath"
srcpath="${src.dir}/compiler"
params="-optimise ${scalac.args}"
srcdir="${src.dir}/compiler"
2008-10-30 23:04:59 +08:00
jvmargs="${scalacfork.jvmargs}">
2008-10-24 21:53:46 +08:00
<include name= "**/*.scala" />
<compilationpath >
2008-10-28 18:59:01 +08:00
<pathelement location= "${build-optimised.dir}/classes/library" />
<pathelement location= "${build-optimised.dir}/classes/compiler" />
2008-10-24 21:53:46 +08:00
<pathelement location= "${fjbg.jar}" />
<pathelement location= "${msil.jar}" />
<pathelement location= "${jline.jar}" />
<pathelement location= "${ant.jar}" />
</compilationpath>
</scalacfork>
<propertyfile file= "${build-optimised.dir}/classes/compiler/compiler.properties" >
<entry key= "version.number" value= "${version.number}" />
<entry key= "copyright.string" value= "${copyright.string}" />
</propertyfile>
<copy todir= "${build-optimised.dir}/classes/compiler" >
<fileset dir= "${src.dir}/compiler" >
<include name= "**/*.tmpl" />
<include name= "**/*.xml" />
<include name= "**/*.js" />
<include name= "**/*.css" />
</fileset>
</copy>
<touch file= "${build-optimised.dir}/compiler.complete" verbose= "no" />
<stopwatch name= "optimised.comp.timer" action= "total" />
</target>
2008-10-30 21:23:59 +08:00
<target name= "optimised.pre-partest" depends= "optimised.comp" >
<uptodate property= "optimised.partest.available" targetfile= "${build-optimised.dir}/partest.complete" >
<srcfiles dir= "${src.dir}/partest" />
</uptodate>
</target>
2008-11-11 23:46:36 +08:00
2008-10-30 21:23:59 +08:00
<target name= "optimised.partest" depends= "optimised.pre-partest" unless= "optimised.partest.available" >
<stopwatch name= "optimised.partest.timer" />
<mkdir dir= "${build-optimised.dir}/classes/partest" />
<javac
srcdir="${src.dir}/partest"
destdir="${build-optimised.dir}/classes/partest"
target="1.5" source="1.5">
<classpath >
2008-11-11 23:46:36 +08:00
<pathelement location= "${build-optimised.dir}/classes/library" />
<pathelement location= "${build-optimised.dir}/classes/compiler" />
<pathelement location= "${build-optimised.dir}/classes/partest" />
2008-10-30 21:23:59 +08:00
</classpath>
<include name= "**/*.java" />
<compilerarg line= "${javac.args}" />
</javac>
<scalacfork
destdir="${build-optimised.dir}/classes/partest"
compilerpathref="locker.classpath"
srcpath="${src.dir}/partest"
params="${scalac.args}"
srcdir="${src.dir}/partest"
maxmemory="${scalacfork.maxmemory}">
<include name= "**/*.scala" />
<compilationpath >
2008-11-11 23:46:36 +08:00
<pathelement location= "${build-optimised.dir}/classes/library" />
<pathelement location= "${build-optimised.dir}/classes/compiler" />
<pathelement location= "${build-optimised.dir}/classes/partest" />
2008-10-30 21:23:59 +08:00
<pathelement location= "${ant.jar}" />
</compilationpath>
</scalacfork>
<copy todir= "${build-optimised.dir}/classes/partest" >
<fileset dir= "${src.dir}/partest" >
<include name= "**/*.xml" />
</fileset>
</copy>
<touch file= "${build-optimised.dir}/partest.complete" verbose= "no" />
<stopwatch name= "optimised.partest.timer" action= "total" />
</target>
<target name= "optimised.pre-bin" depends= "optimised.partest" >
<condition property= "optimised.bin.available" >
<isset property= "optimised.comp.available" />
</condition>
</target>
<target name= "optimised.bin" depends= "optimised.pre-bin" unless= "optimised.bin.available" >
<path id= "optimised.bin.classpath" >
2008-11-11 23:46:36 +08:00
<pathelement location= "${build-optimised.dir}/classes/library" />
<pathelement location= "${build-optimised.dir}/classes/compiler" />
2008-10-30 21:23:59 +08:00
<pathelement location= "${fjbg.jar}" />
<pathelement location= "${jline.jar}" />
</path>
<taskdef name= "optimised-bin" classname= "scala.tools.ant.ScalaTool" classpathref= "optimised.bin.classpath" />
<mkdir dir= "${build-optimised.dir}/bin" />
<optimised-bin
file="${build-optimised.dir}/bin/scala"
class="scala.tools.nsc.MainGenericRunner"
javaFlags="${java.flags}"
classpathref="optimised.bin.classpath"/>
<optimised-bin
file="${build-optimised.dir}/bin/scalac"
class="scala.tools.nsc.Main"
javaFlags="${java.flags}"
classpathref="optimised.bin.classpath"/>
<optimised-bin
file="${build-optimised.dir}/bin/scaladoc"
class="scala.tools.nsc.ScalaDoc"
javaFlags="${java.flags}"
classpathref="optimised.bin.classpath"/>
<optimised-bin
file="${build-optimised.dir}/bin/fsc"
class="scala.tools.nsc.CompileClient"
javaFlags="${java.flags}"
classpathref="optimised.bin.classpath"/>
<chmod perm= "ugo+rx" file= "${build-optimised.dir}/bin/scala" />
<chmod perm= "ugo+rx" file= "${build-optimised.dir}/bin/scalac" />
<chmod perm= "ugo+rx" file= "${build-optimised.dir}/bin/scaladoc" />
<chmod perm= "ugo+rx" file= "${build-optimised.dir}/bin/fsc" />
<touch file= "${build-optimised.dir}/bin.complete" verbose= "no" />
</target>
2008-11-20 19:07:10 +08:00
<target name= "optimised.done" depends= "optimised.bin" >
<path id= "optimised.classpath" >
<pathelement location= "${build-optimised.dir}/classes/library" />
<pathelement location= "${build-optimised.dir}/classes/compiler" />
<pathelement location= "${build-optimised.dir}/classes/partest" />
<pathelement location= "${fjbg.jar}" />
<pathelement location= "${ant.jar}" />
</path>
</target>
2008-10-30 21:23:59 +08:00
2008-10-24 21:53:46 +08:00
<target name= "optimised.clean" >
<delete dir= "${build-optimised.dir}" includeemptydirs= "yes" quiet= "yes" failonerror= "no" />
</target>
2005-12-24 02:17:24 +08:00
<!-- ===========================================================================
2006-03-08 00:42:36 +08:00
DOCUMENTATION
2005-12-24 02:17:24 +08:00
============================================================================ -->
2008-05-07 21:17:46 +08:00
<target name= "docs.start" depends= "pack.done" />
<target name= "docs.pre-lib" depends= "docs.start" >
<uptodate property= "docs.lib.available" targetfile= "${build-docs.dir}/library.complete" >
<srcfiles dir= "${src.dir}" >
<include name= "library/**" />
<include name= "dbc/**" />
<include name= "actors/**" />
2008-07-30 18:27:43 +08:00
<include name= "swing/**" />
2008-05-07 21:17:46 +08:00
</srcfiles>
</uptodate>
2005-12-19 21:49:03 +08:00
</target>
2006-04-13 00:55:00 +08:00
2008-05-07 21:17:46 +08:00
<target name= "docs.lib" depends= "docs.pre-lib" unless= "docs.lib.available" >
<stopwatch name= "docs.lib.timer" />
<mkdir dir= "${build-docs.dir}/library" />
<scaladoc
destdir="${build-docs.dir}/library"
windowtitle="Scala Library"
doctitle="Scala ${version.number} API"
classpathref="pack.classpath">
<src >
<files includes= "${src.dir}/actors" />
<files includes= "${src.dir}/library/scala" />
2008-10-16 18:44:32 +08:00
<files includes= "${src.dir}/swing" />
2008-05-07 21:17:46 +08:00
</src>
2006-03-09 05:37:50 +08:00
<include name= "**/*.scala" />
2008-05-07 21:17:46 +08:00
<exclude name= "reflect/Code.scala" />
<exclude name= "reflect/Manifest.scala" />
<exclude name= "reflect/Print.scala" />
<exclude name= "reflect/Symbol.scala" />
<exclude name= "reflect/Tree.scala" />
<exclude name= "reflect/Type.scala" />
<exclude name= "reflect/TypedCode.scala" />
<exclude name= "runtime/*Array.scala" />
<exclude name= "runtime/*$.scala" />
<exclude name= "runtime/ScalaRunTime.scala" />
<exclude name= "runtime/StreamCons.scala" />
<exclude name= "runtime/StringAdd.scala" />
</scaladoc>
<touch file= "${build-docs.dir}/library.complete" verbose= "no" />
<stopwatch name= "docs.lib.timer" action= "total" />
</target>
2008-06-09 21:11:17 +08:00
<target name= "docs.pre-man" depends= "docs.lib" >
<uptodate property= "docs.man.available" targetfile= "${build-docs.dir}/manual.complete" >
<srcfiles dir= "${src.dir}/manual" />
</uptodate>
</target>
<target name= "docs.manmaker" depends= "docs.pre-man" unless= "docs.man.available" >
<mkdir dir= "${build.dir}/manmaker/classes" />
<scalac
destdir="${build.dir}/manmaker/classes"
classpathref="pack.classpath"
srcdir="${src.dir}/manual"
2008-10-11 16:12:42 +08:00
includes="**/*.scala"
addparams="${scalac.args}"/>
2008-06-09 21:11:17 +08:00
<path id= "manual.classpath" >
<pathelement location= "${build-pack.dir}/lib/scala-library.jar" />
<pathelement location= "${build.dir}/manmaker/classes" />
</path>
</target>
<target name= "docs.man" depends= "docs.manmaker" unless= "docs.man.available" >
<mkdir dir= "${build-docs.dir}/manual/man/man1" />
<mkdir dir= "${build-docs.dir}/manual/html" />
2008-10-11 16:12:42 +08:00
<mkdir dir= "${build-docs.dir}/manual/genman/man1" />
2008-06-09 21:11:17 +08:00
<taskdef name= "genman"
classname="scala.tools.docutil.ManMaker"
classpathref="manual.classpath"/>
2008-08-22 23:35:21 +08:00
<genman command= "fsc, sbaz, scala, scalac, scaladoc"
2008-06-09 21:11:17 +08:00
htmlout="${build-docs.dir}/manual/html"
2008-10-11 16:12:42 +08:00
manout="${build-docs.dir}/manual/genman"/>
<!-- On Windows source and target files can't be the same ! -->
<fixcrlf
srcdir="${build-docs.dir}/manual/genman"
destdir="${build-docs.dir}/manual/man"
eol="unix" includes="**/*.1"/>
2008-06-09 21:11:17 +08:00
<copy todir= "${build-docs.dir}/manual/html" >
<fileset dir= "${src.dir}/manual/scala/tools/docutil/resources" >
<include name= "**/*.html" />
<include name= "**/*.css" />
<include name= "**/*.gif" />
<include name= "**/*.png" />
</fileset>
</copy>
<touch file= "${build-docs.dir}/manual.complete" verbose= "no" />
</target>
2008-10-16 18:44:32 +08:00
<target name= "docs.pre-comp" depends= "docs.man" >
2008-05-07 21:17:46 +08:00
<uptodate property= "docs.comp.available" targetfile= "${build-docs.dir}/compiler.complete" >
<srcfiles dir= "${src.dir}/compiler" />
</uptodate>
2006-03-09 05:37:50 +08:00
</target>
2005-12-19 21:49:03 +08:00
2008-05-07 21:17:46 +08:00
<target name= "docs.comp" depends= "docs.pre-comp" unless= "docs.comp.available" >
<stopwatch name= "docs.comp.timer" />
<mkdir dir= "${build-docs.dir}/compiler" />
<scaladoc
destdir="${build-docs.dir}/compiler"
windowtitle="Scala Compiler"
doctitle="Scala Compiler ${version.number} API"
classpathref="pack.classpath"
srcdir="${src.dir}/compiler">
2006-06-12 22:18:13 +08:00
<include name= "**/*.scala" />
2008-05-07 21:17:46 +08:00
</scaladoc>
<touch file= "${build-docs.dir}/compiler.complete" verbose= "no" />
<stopwatch name= "docs.comp.timer" action= "total" />
2006-06-12 22:18:13 +08:00
</target>
2008-08-12 19:00:53 +08:00
2008-10-16 18:44:32 +08:00
<target name= "docs.done" depends= "docs.man" />
2006-06-12 22:18:13 +08:00
2008-05-07 21:17:46 +08:00
<target name= "docs.clean" >
<delete dir= "${build-docs.dir}" includeemptydirs= "yes" quiet= "yes" failonerror= "no" />
2008-06-09 21:11:17 +08:00
<delete dir= "${build.dir}/manmaker" includeemptydirs= "yes" quiet= "yes" failonerror= "no" />
2008-05-07 21:17:46 +08:00
</target>
2008-11-11 23:46:36 +08:00
2005-12-24 02:17:24 +08:00
<!-- ===========================================================================
2008-05-07 21:17:46 +08:00
BOOTRAPING TEST AND TEST SUITE
2005-12-24 02:17:24 +08:00
============================================================================ -->
2008-11-11 23:46:36 +08:00
2008-05-07 21:17:46 +08:00
<target name= "test.stability" depends= "strap.done" >
<same dir= "${build-quick.dir}" todir= "${build-strap.dir}" failondifferent= "no" >
<exclude name= "**/*.properties" />
<exclude name= "bin/**" />
<exclude name= "*.complete" />
</same>
2006-03-09 23:16:53 +08:00
</target>
2006-03-17 03:35:29 +08:00
2008-10-31 23:25:27 +08:00
<target name= "test.run" depends= "pack.done" >
<partest showlog= "yes" erroronfailed= "yes" javacmd= "${java.home}/bin/java"
timeout="1200000" javaccmd="${javac.cmd}">
<classpath >
<path refid= "pack.classpath" />
<fileset dir= "${test.dir}/files/lib" includes= "*.jar" />
</classpath>
<runtests dir= "${test.dir}/files" >
<include name= "run/**/*.scala" />
<include name= "jvm/**/*.scala" />
</runtests>
<jvm5tests dir= "${test.dir}/files/jvm5" includes= "*.scala" />
</partest>
</target>
2008-05-07 21:17:46 +08:00
<target name= "test.suite" depends= "pack.done" >
2008-07-09 01:55:14 +08:00
<partest showlog= "yes" erroronfailed= "yes" javacmd= "${java.home}/bin/java"
2008-10-22 03:04:52 +08:00
timeout="1200000" javaccmd="${javac.cmd}">
2008-05-07 21:17:46 +08:00
<classpath >
<path refid= "pack.classpath" />
<fileset dir= "${test.dir}/files/lib" includes= "*.jar" />
</classpath>
2008-10-29 06:41:49 +08:00
<postests dir= "${test.dir}/files/pos" includes= "*.scala" />
<pos5tests dir= "${test.dir}/files/pos5" includes= "*.scala" />
<negtests dir= "${test.dir}/files/neg" includes= "*.scala" />
<runtests dir= "${test.dir}/files" >
2008-05-07 21:17:46 +08:00
<include name= "run/**/*.scala" />
<include name= "jvm/**/*.scala" />
</runtests>
2008-10-31 23:25:27 +08:00
<jvm5tests dir= "${test.dir}/files/jvm5" includes= "*.scala" />
2008-05-07 21:17:46 +08:00
<residenttests dir= "${test.dir}/files/res" includes= "*.res" />
2008-08-01 02:18:35 +08:00
<!-- <scripttests dir="${test.dir}/files/script" includes="*.scala"/> -->
2008-07-31 21:47:13 +08:00
<shootouttests dir= "${test.dir}/files/shootout" includes= "*.scala" />
2008-05-07 21:17:46 +08:00
</partest>
2006-03-13 18:36:32 +08:00
</target>
2008-05-07 21:17:46 +08:00
<target name= "test.done" depends= "test.suite, test.stability" />
2006-03-17 03:35:29 +08:00
2008-11-20 19:07:10 +08:00
<target name= "optimised.test.suite" depends= "optimised.done" >
<taskdef resource= "scala/tools/partest/antlib.xml" classpathref= "optimised.classpath" />
<partest showlog= "yes" erroronfailed= "yes" javacmd= "${java.home}/bin/java"
timeout="1200000" javaccmd="${javac.cmd}">
<classpath >
<path refid= "optimised.classpath" />
<fileset dir= "${test.dir}/files/lib" includes= "*.jar" />
</classpath>
<postests dir= "${test.dir}/files/pos" includes= "*.scala" />
<pos5tests dir= "${test.dir}/files/pos5" includes= "*.scala" />
<negtests dir= "${test.dir}/files/neg" includes= "*.scala" />
<runtests dir= "${test.dir}/files" >
<include name= "run/**/*.scala" />
<include name= "jvm/**/*.scala" />
<include name= "jvm5/**/*.scala" />
</runtests>
<residenttests dir= "${test.dir}/files/res" includes= "*.res" />
<!-- <scripttests dir="${test.dir}/files/script" includes="*.scala"/> -->
<shootouttests dir= "${test.dir}/files/shootout" includes= "*.scala" />
</partest>
</target>
<target name= "optimised.test.done" depends= "optimised.test.suite" />
2008-05-07 21:17:46 +08:00
<!-- ===========================================================================
DISTRIBUTION
============================================================================ -->
<target name= "dist.start" depends= "docs.done, pack.done" >
<property name= "dist.dir" value= "${dists.dir}/scala-${version.number}" />
2006-03-09 23:16:53 +08:00
</target>
2008-05-07 21:17:46 +08:00
<target name= "dist.base" depends= "dist.start" >
<mkdir dir= "${dist.dir}/lib" />
<copy toDir= "${dist.dir}/lib" >
<fileset dir= "${build-pack.dir}/lib" />
2006-05-11 23:29:25 +08:00
</copy>
2008-05-07 21:17:46 +08:00
<mkdir dir= "${dist.dir}/bin" />
<copy toDir= "${dist.dir}/bin" >
<fileset dir= "${build-pack.dir}/bin" />
2006-03-16 00:59:10 +08:00
</copy>
2008-05-07 21:17:46 +08:00
<chmod perm= "ugo+rx" file= "${dist.dir}/bin/scala" />
<chmod perm= "ugo+rx" file= "${dist.dir}/bin/scalac" />
<chmod perm= "ugo+rx" file= "${dist.dir}/bin/scaladoc" />
<chmod perm= "ugo+rx" file= "${dist.dir}/bin/fsc" />
</target>
2008-05-13 23:29:28 +08:00
2008-11-10 01:55:15 +08:00
<target name= "dist.doc" depends= "dist.base" >
2008-08-12 23:38:03 +08:00
<mkdir dir= "${dist.dir}/doc/scala-devel-docs" />
<copy file= "${docs.dir}/LICENSE" toDir= "${dist.dir}/doc/scala-devel-docs" />
<copy file= "${docs.dir}/README" toDir= "${dist.dir}/doc/scala-devel-docs" />
<mkdir dir= "${dist.dir}/doc/scala-devel-docs/api" />
<copy toDir= "${dist.dir}/doc/scala-devel-docs/api" >
2008-05-07 21:17:46 +08:00
<fileset dir= "${build-docs.dir}/library" />
2006-03-09 05:37:50 +08:00
</copy>
2008-08-12 23:38:03 +08:00
<mkdir dir= "${dist.dir}/doc/scala-devel-docs/examples" />
<copy toDir= "${dist.dir}/doc/scala-devel-docs/examples" >
2006-05-11 23:29:25 +08:00
<fileset dir= "${docs.dir}/examples" />
2006-03-09 22:13:01 +08:00
</copy>
2008-08-12 23:38:03 +08:00
<mkdir dir= "${dist.dir}/doc/scala-devel-docs/tools" />
<copy toDir= "${dist.dir}/doc/scala-devel-docs/tools" >
2008-06-09 21:11:17 +08:00
<fileset dir= "${build-docs.dir}/manual/html" />
</copy>
2008-10-16 18:44:32 +08:00
<copy file= "${src.dir}/swing/doc/README"
toFile="${dist.dir}/doc/scala-devel-docs/README.scala-swing"/>
2008-05-07 21:17:46 +08:00
</target>
2008-11-11 23:46:36 +08:00
2008-05-07 21:17:46 +08:00
<target name= "dist.man" depends= "dist.doc" >
<mkdir dir= "${dist.dir}/man" />
<copy toDir= "${dist.dir}/man" >
2008-06-09 21:11:17 +08:00
<fileset dir= "${build-docs.dir}/manual/man" />
2006-06-08 23:11:48 +08:00
</copy>
2006-05-11 23:29:25 +08:00
</target>
2008-05-09 15:36:20 +08:00
2008-05-07 21:17:46 +08:00
<target name= "dist.src" depends= "dist.man" >
<mkdir dir= "${dist.dir}/src" />
<jar destfile= "${dist.dir}/src/scala-library-src.jar" >
<fileset dir= "${src.dir}/library" />
<fileset dir= "${src.dir}/actors" />
</jar>
<jar destfile= "${dist.dir}/src/scala-dbc-src.jar" >
<fileset dir= "${src.dir}/dbc" />
</jar>
2008-07-30 18:27:43 +08:00
<jar destfile= "${dist.dir}/src/scala-swing-src.jar" >
<fileset dir= "${src.dir}/swing" />
</jar>
2008-05-07 21:17:46 +08:00
<jar destfile= "${dist.dir}/src/scala-compiler-src.jar" >
<fileset dir= "${src.dir}/compiler" />
</jar>
2005-12-19 21:49:03 +08:00
</target>
2008-11-10 01:55:15 +08:00
<target name= "dist.latest.unix" depends= "dist.src" unless= "os.win" >
<symlink link= "${dists.dir}/latest" resource= "${dist.dir}" overwrite= "yes" />
</target>
<target name= "dist.latest.win" depends= "dist.src" if= "os.win" >
<copy todir= "${dists.dir}/latest" >
<fileset dir= "${dist.dir}" />
</copy>
</target>
<target name= "dist.latest" depends= "dist.latest.unix,dist.latest.win" />
2008-11-11 23:46:36 +08:00
2008-11-10 01:55:15 +08:00
<target name= "dist.done" depends= "dist.latest" />
2005-12-24 02:17:24 +08:00
2008-05-07 21:17:46 +08:00
<target name= "dist.clean" >
<delete dir= "${dists.dir}" includeemptydirs= "yes" quiet= "yes" failonerror= "no" />
2006-05-08 19:53:59 +08:00
</target>
2005-12-24 02:17:24 +08:00
<!-- ===========================================================================
2008-05-07 21:17:46 +08:00
TEST AND DISTRIBUTION BUNDLE (ALL)
2005-12-24 02:17:24 +08:00
============================================================================ -->
2008-05-09 15:36:20 +08:00
2008-05-09 17:04:25 +08:00
<target name= "all.done" depends= "dist.done, test.done" />
2008-05-09 15:36:20 +08:00
2008-05-07 21:17:46 +08:00
<target name= "all.clean" depends= "locker.clean, docs.clean, dist.clean" />
2006-03-02 22:01:45 +08:00
2008-05-07 21:17:46 +08:00
<!-- ===========================================================================
STABLE REFERENCE (STARR)
============================================================================ -->
2008-09-03 03:31:24 +08:00
<!-- Does not use any properties other than ${basedir}, so that it can
run without 'init' (when using 'newstarrwin') -->
<target name= "starr.start" >
<fail message= "Library in build/pack not available" >
<condition > <not > <and >
<available file= "${basedir}/build/pack/lib/scala-library.jar" />
</and> </not> </condition>
</fail>
<fail message= "Compiler in build/quick not available" >
<condition > <not > <and >
<available file= "${basedir}/build/quick/classes/compiler" />
<available file= "${basedir}/build/quick/compiler.complete" />
</and> </not> </condition>
</fail>
2006-03-06 22:12:09 +08:00
</target>
2008-09-03 03:31:24 +08:00
<target name= "starr.clean" depends= "starr.start" >
<delete file= "${basedir}/lib/scala-library.jar" />
<delete file= "${basedir}/lib/scala-compiler.jar" />
<delete file= "${basedir}/lib/scala-library-src.jar" />
</target>
2008-05-07 21:17:46 +08:00
<target name= "starr.lib" depends= "starr.clean" >
2008-09-03 03:31:24 +08:00
<copy file= "${basedir}/build/pack/lib/scala-library.jar"
toFile="${basedir}/lib/scala-library.jar"/>
2008-05-07 21:17:46 +08:00
</target>
2008-09-03 03:31:24 +08:00
2008-05-07 21:17:46 +08:00
<target name= "starr.comp" depends= "starr.lib" >
2008-09-03 03:31:24 +08:00
<jar destfile= "${basedir}/lib/scala-compiler.jar" >
<fileset dir= "${basedir}/build/quick/classes/compiler" />
2008-05-07 21:17:46 +08:00
</jar>
2005-12-19 21:49:03 +08:00
</target>
2008-09-03 03:31:24 +08:00
2008-05-07 21:17:46 +08:00
<target name= "starr.src" depends= "starr.comp" >
2008-09-03 03:31:24 +08:00
<jar destfile= "${basedir}/lib/scala-library-src.jar" >
<fileset dir= "${basedir}/src/library" />
<fileset dir= "${basedir}/src/actors" />
2008-05-07 21:17:46 +08:00
</jar>
</target>
2008-09-03 03:31:24 +08:00
2008-05-07 21:17:46 +08:00
<target name= "starr.done" depends= "starr.src" />
2006-03-02 22:01:45 +08:00
2008-05-07 21:17:46 +08:00
<!-- ===========================================================================
FORWARDED TARGETS FOR JVM 1.4 BUILD
============================================================================ -->
<target name= "four" depends= "pack.done" >
<ant antfile= "${src.dir}/build/four.xml" target= "four-pack.done" inheritall= "yes" inheritrefs= "yes" />
</target>
2008-10-28 18:59:01 +08:00
2008-05-07 21:17:46 +08:00
<target name= "fourtest" depends= "pack.done" >
<ant antfile= "${src.dir}/build/four.xml" target= "four-test.done" inheritall= "yes" inheritrefs= "yes" />
</target>
2008-10-28 18:59:01 +08:00
2008-05-07 21:17:46 +08:00
<target name= "fourdist" depends= "pack.done" >
<ant antfile= "${src.dir}/build/four.xml" target= "four-all.done" inheritall= "yes" inheritrefs= "yes" />
</target>
2008-10-28 18:59:01 +08:00
2008-05-07 21:17:46 +08:00
<target name= "fourclean" >
<ant antfile= "${src.dir}/build/four.xml" target= "four-all.clean" inheritall= "yes" inheritrefs= "yes" />
</target>
2008-10-28 18:59:01 +08:00
2008-05-07 21:17:46 +08:00
<!-- ===========================================================================
FORWARDED TARGETS FOR MSIL BUILD
============================================================================ -->
2008-05-09 15:36:20 +08:00
2008-05-09 23:47:25 +08:00
<target name= "msil" depends= "pack.done" >
2008-05-08 16:04:41 +08:00
<ant antfile= "${src.dir}/build/msil.xml" target= "msil-pack.done" inheritall= "yes" inheritrefs= "yes" />
2008-05-07 21:17:46 +08:00
</target>
2008-05-09 15:36:20 +08:00
2008-05-09 18:28:21 +08:00
<target name= "msiltest" />
<target name= "msildist" depends= "pack.done" >
<ant antfile= "${src.dir}/build/msil.xml" target= "msil-all.done" inheritall= "yes" inheritrefs= "yes" />
</target>
2008-05-07 21:17:46 +08:00
<target name= "msilclean" >
2008-05-09 18:28:21 +08:00
<ant antfile= "${src.dir}/build/msil.xml" target= "msil-all.clean" inheritall= "yes" inheritrefs= "yes" />
2007-02-13 16:35:18 +08:00
</target>
2008-05-07 21:17:46 +08:00
<!-- ===========================================================================
FORWARDED TARGETS FOR PACKAGING
============================================================================ -->
2008-05-09 17:04:25 +08:00
<target name= "distpack" depends= "dist.done" >
2008-05-07 21:17:46 +08:00
<ant antfile= "${src.dir}/build/pack.xml" target= "pack-all.done" inheritall= "yes" inheritrefs= "yes" />
</target>
2008-05-09 22:20:54 +08:00
<target name= "fourdistpack" depends= "pack.done" >
<ant antfile= "${src.dir}/build/four.xml" target= "four-dist.done" inheritall= "yes" inheritrefs= "yes" />
2008-05-07 21:17:46 +08:00
<ant antfile= "${src.dir}/build/pack.xml" target= "fourpack-all.done" inheritall= "yes" inheritrefs= "yes" />
2007-06-13 20:14:52 +08:00
</target>
2008-05-09 22:20:54 +08:00
<target name= "msildistpack" depends= "pack.done" >
<ant antfile= "${src.dir}/build/msil.xml" target= "msil-dist.done" inheritall= "yes" inheritrefs= "yes" />
2008-05-09 18:28:21 +08:00
<ant antfile= "${src.dir}/build/pack.xml" target= "msilpack-all.done" inheritall= "yes" inheritrefs= "yes" />
</target>
2008-08-14 16:40:44 +08:00
<!-- Used by the scala - installer script -->
2008-08-12 19:00:53 +08:00
<target name= "alldistpack" depends= "distpack, fourdistpack, msildistpack" />
2008-08-14 16:40:44 +08:00
<target name= "allallclean" depends= "all.clean, fourclean, msilclean" />
2008-08-12 19:00:53 +08:00
2008-05-07 21:17:46 +08:00
<!-- ===========================================================================
FORWARDED TARGETS FOR NIGHTLY BUILDS
============================================================================ -->
2008-10-28 18:59:01 +08:00
2008-05-07 21:17:46 +08:00
<target name= "nightly" depends= "all.done" >
<ant antfile= "${src.dir}/build/pack.xml" target= "pack-all.done" inheritall= "yes" inheritrefs= "yes" />
</target>
2008-10-28 18:59:01 +08:00
2008-05-07 21:17:46 +08:00
<target name= "fournightly" depends= "pack.done" >
<ant antfile= "${src.dir}/build/four.xml" target= "four-all.done" inheritall= "yes" inheritrefs= "yes" />
<ant antfile= "${src.dir}/build/pack.xml" target= "fourpack-all.done" inheritall= "yes" inheritrefs= "yes" />
2006-01-21 00:15:13 +08:00
</target>
2008-10-28 18:59:01 +08:00
2008-05-09 23:47:25 +08:00
<target name= "fourfournightly" >
<ant antfile= "${src.dir}/build/four.xml" target= "fourfour-test.done" />
</target>
2008-05-09 18:28:21 +08:00
<target name= "msilnightly" depends= "pack.done" >
2008-05-10 20:09:38 +08:00
<ant antfile= "${src.dir}/build/msil.xml" target= "msil-all.done" inheritall= "yes" inheritrefs= "yes" />
2008-05-09 18:28:21 +08:00
<ant antfile= "${src.dir}/build/pack.xml" target= "msilpack-all.done" inheritall= "yes" inheritrefs= "yes" />
</target>
2006-03-02 22:01:45 +08:00
2008-05-07 21:17:46 +08:00
<!-- ===========================================================================
MISCELLANEOUS
============================================================================ -->
2008-10-28 18:59:01 +08:00
2008-05-07 21:17:46 +08:00
<target name= "graph.init" >
<taskdef name= "vizant" classname= "vizant.Vizant" classpath= "${lib-ant.dir}/vizant.jar" />
</target>
2008-10-28 18:59:01 +08:00
2008-05-07 21:17:46 +08:00
<target name= "graph.clean" depends= "graph.init" >
<vizant antfile= "${ant.file}" outfile= "${ant.project.name}.dot" from= "starr.clean" />
</target>
2008-10-28 18:59:01 +08:00
2008-05-07 21:17:46 +08:00
<target name= "graph.all" depends= "graph.init" >
<vizant antfile= "${ant.file}" outfile= "${ant.project.name}.dot" from= "all.done" />
</target>
2008-10-28 18:59:01 +08:00
2008-05-07 21:17:46 +08:00
<target name= "graph.sabbus" depends= "graph.init" >
<vizant antfile= "${ant.file}" outfile= "${ant.project.name}.dot" />
2005-12-19 21:49:03 +08:00
</target>
2005-10-11 17:39:32 +08:00
</project>