-<project name="xwt" default="run" basedir=".">
+<project name="xwt" default="compile" basedir=".">
<!-- required so that libgcj.jar doesn't interfere with non-gcj compilation -->
<property name="build.sysclasspath" value="first"/>
<!-- purges binaries we've built -->
<target name="clean">
- <bash>
- find . -name \*\~ | xargs rm -f
- find . -name \#\*\# | xargs rm -f
- rm -rf bin-* bin
- </bash>
+ <delete quiet="true" dir="bin"/>
+ <delete quiet="true">
+ <fileset dir="./" casesensitive="yes" defaultexcludes="no">
+ <include name="bin-*"/>
+ <include name="**/*~"/>
+ <include name="**/#*#"/>
+ <exclude name="**/.#*"/>
+ <exclude name="**/%*%"/>
+ <exclude name="**/._*"/>
+ <exclude name="**/CVS"/>
+ <exclude name="**/CVS/**"/>
+ <exclude name="**/.cvsignore"/>
+ <exclude name="**/SCCS"/>
+ <exclude name="**/SCCS/**"/>
+ <exclude name="**/vssver.scc"/>
+ <exclude name="**/.svn"/>
+ <exclude name="**/.svn/**"/>
+ </fileset>
+ </delete>
</target>
<!-- compiles all .java files into .class files; all other tasks predepend on this since they need the <taskdef/>'s -->
<target name="compile">
<mkdir dir="bin/"/>
- <echo message="compiling .java -> .class"/>
+ <echo message="compiling .java -> .class [xwt]"/>
<javac destdir="bin/" deprecation="no">
<src path="src/"/>
<include name="**/*.java"/>
<classpath>
+
<!-- don't EVER include the following line anywhere else; it causes really bizarre errors -->
<pathelement location="${gcc-path}/share/libgcj.jar"/>
<path refid="classpath"/>
+
+ <!-- this is for people who don't have libgcj.jar -->
+ <pathelement location="lib/libgcj-minimal.jar"/>
+
</classpath>
</javac>
- <taskdef name="bash" classname="org.xwt.tasks.BashTask">
- <classpath path="bin/"/>
- </taskdef>
+ <echo message="updating .xwt -> .xwar"/>
+ <zip update="true" zipfile="bin/org/xwt/builtin.xwar" basedir="src" includes="org/xwt/builtin/*.png,org/xwt/builtin/*.xwt,org/xwt/builtin/*.xwf"/>
</target>
<target name="build" depends="compile">
<ant dir="." antfile="src/org/xwt/plat/${plat}.xml" target="build"/>
</target>
- <target name="run" depends="compile,build">
- <ant dir="." antfile="src/org/xwt/plat/${plat}.xml" target="run"/>
- </target>
-
</project>
-
-
- <!-- old javago optimization code - - reintegrate at some point
- lib/javago.`uname` -threshold 300 -not-inline-constructor -not-use-invokespecial org/xwt/Box.class
- lib/javago.`uname` -threshold 300 -not-inline-constructor -not-use-invokespecial org/xwt/Box.class
- lib/javago.`uname` -threshold 200 -not-inline-constructor -not-use-invokespecial org/xwt/Surface.class
- lib/javago.`uname` -threshold 50 -not-inline-constructor -not-use-invokespecial org/xwt/GetPutHandler*
- lib/javago.`uname` -threshold 200 -not-inline-constructor -not-use-invokespecial org/xwt/util/DirtyList.class
- -->