+++ /dev/null
-<!-- Copyright 2002 Adam Megacz, see the COPYING file for licensing [GPL] -->
-<!--
-
- Subclasses of org.xwt.plat.GCJ should include a .xml file which
- sets the following properties, then invokes <ant antfile="src/org/xwt/plat/GCJ.xml"/>
-
- gcc-target - the gcc target name to use (for example, i686-pc-mingw32)
- linkflags - extra flags to pass to gcj during the link phase, if any
- binaryname - the name to give to the final binary
-
--->
-
-<project name="GCJ" default="build">
-
- <target name="build">
-
- <echo message='extracting .class -> .h'/>
- <taskdef name='gcjh' classname='org.xwt.tasks.GCJHTask'>
- <classpath path='bin/'/>
- </taskdef>
- <gcjh out='bin-${plat}' classpath='bin'/>
-
- <echo message='compiling .java -> .o'/>
- <apply failonerror='true' executable='${gcc-path}/bin/${gcc-target}gcj' dest='bin-${plat}'>
- <arg value='-fCLASSPATH=bin/'/>
- <arg value='-O9'/>
- <arg value='-ffast-math'/>
- <arg value='-fomit-frame-pointer'/>
- <arg value='-foptimize-sibling-calls'/>
- <arg value='-finline-functions'/>
- <arg value='-funroll-loops'/>
- <arg value='-g'/>
- <arg value='-c'/>
- <srcfile/>
- <arg value='-o'/>
- <targetfile/>
- <fileset dir='src/' includes='${javafiles}'>
- <include name='org/xwt/*.java'/>
- <include name='org/xwt/util/*.java'/>
- <include name='org/xwt/plat/GCJ.java'/>
- <include name='org/bouncycastle/**/*.java'/>
- <include name='org/mozilla/**/*.java'/>
- <exclude name='org/xwt/Trap.java'/>
- </fileset>
- <mapper type='glob' from='*.java' to='*.o'/>
- </apply>
-
- <!-- we have to turn off optimization here due to a compiler bug -->
- <apply failonerror='true' executable='${gcc-path}/bin/${gcc-target}gcj' dest='bin-${plat}'>
- <arg value='-fCLASSPATH=bin/'/>
- <arg value='-O0'/>
- <arg value='-ffast-math'/>
- <arg value='-fomit-frame-pointer'/>
- <arg value='-foptimize-sibling-calls'/>
- <arg value='-finline-functions'/>
- <arg value='-funroll-loops'/>
- <arg value='-g'/>
- <arg value='-c'/>
- <srcfile/>
- <arg value='-o'/>
- <targetfile/>
- <fileset dir='src/'>
- <include name='org/xwt/Trap.java'/>
- </fileset>
- <mapper type='glob' from='*.java' to='*.o'/>
- </apply>
-
- <echo message='compiling .cc -> .o'/>
- <apply failonerror='true' executable='${gcc-path}/bin/${gcc-target}gcj' dest='bin-${plat}/'>
- <arg value='-g'/>
- <arg value='-Ibin-${plat}'/>
- <arg value='-c'/>
- <srcfile/>
- <arg value='-o'/>
- <targetfile/>
- <fileset dir='src/' includes='${ccfiles}'/>
- <mapper type='glob' from='*.cc' to='*-nat.o'/>
- </apply>
-
- <echo message='wrapping .xwar -> .o'/>
- <apply failonerror='true' executable='${gcc-path}/bin/${gcc-target}gcj' dest='bin-${plat}/'>
- <fileset dir='bin/' includes='**/*.xwar'/>
- <arg value='--resource'/>
- <arg value='org/xwt/builtin.xwar'/>
- <arg value='-c'/>
- <srcfile/>
- <arg value='-o'/>
- <targetfile/>
- <mapper type='glob' from='*.xwar' to='*.o'/>
- </apply>
-
- <echo message='linking .o -> ${binaryname}'/>
- <uptodate property="linked" targetfile="bin-${plat}/${binaryname}">
- <srcfiles dir="bin-${plat}/" includes="**/*.o" excludes='*.o'/>
- </uptodate>
- <antcall target="link"/>
-
- </target>
-
- <target name="link" unless="linked">
- <apply failonerror='true' executable='${gcc-path}/bin/${gcc-target}gcj' parallel='true'>
- <fileset dir='bin-${plat}/' includes='**/*.o' excludes='*.o'/>
- <arg value='-fCLASSPATH=${gcc-path}/share/libgcj.jar'/>
- <arg value='--main=org.xwt.Main'/>
- <arg line='-o bin-${plat}/${binaryname}'/>
- <srcfile/>
- <arg line='${linkflags}'/>
- </apply>
- </target>
-
-</project>
-
-
+++ /dev/null
-<!-- Copyright 2002 Adam Megacz, see the COPYING file for licensing [GPL] -->
-
-<project name="Linux" default="build">
-
- <target name="build">
- <property name="gcc-target" value=""/>
- <property name="linkflags" value="-L${gcc-path}/lib -L/usr/X11R6/lib -lX11 -lXext --static"/>
- <property name="binaryname" value="xwt"/>
- <property name="ccfiles" value="org/xwt/plat/X11.cc,org/xwt/plat/POSIX.cc"/>
- <property name="javafiles" value="org/xwt/plat/X11.java,org/xwt/plat/POSIX.java"/>
- <ant target="build" antfile="src/org/xwt/plat/GCJ.xml"/>
- </target>
-
- <target name="run">
- <echo message='launching xwt.linux'/>
- <bash> bin-Linux/xwt.linux </bash>
- </target>
-
-</project>
+++ /dev/null
-<!-- Copyright 2002 Adam Megacz, see the COPYING file for licensing [GPL] -->
-
-<project name="Win32" default="build">
-
- <target name="build">
- <property name="gcc-target" value="i686-pc-mingw32-"/>
- <property name="linkflags" value="-Wl,--subsystem,windows -lcomdlg32"/>
- <property name="binaryname" value="xwt.exe"/>
- <property name="javafiles" value="org/xwt/plat/Win32.java"/>
- <property name="ccfiles" value="org/xwt/plat/Win32.cc"/>
- <ant target="build" antfile="src/org/xwt/plat/GCJ.xml"/>
- </target>
-
- <target name="run">
- <echo message='launching .exe'/>
- <exec dir='.' executable='/usr/bin/ssh'>
- <arg value='${cygwin-host}'/>
- <arg value='cd ${cygwin-path}; bin-Win32/xwt.exe src org.xwt.demo.main'/>
- </exec>
- </target>
-
-</project>