diff options
author | Kenneth Russel <[email protected]> | 2008-05-13 11:17:23 +0000 |
---|---|---|
committer | Kenneth Russel <[email protected]> | 2008-05-13 11:17:23 +0000 |
commit | a640c7c0c77199ef12b880a3de583cede5435691 (patch) | |
tree | f27434e5cbf1424b355c1873e4fcd29f0c7bcccf /make/build.xml | |
parent | 11191045c9b4cff294b180573afaa327d0e6766c (diff) |
Refactorings to support building JOGL and supporting libraries on
Java ME / CDC / FP
git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/../svn-server-sync/gluegen/trunk@75 a78bb65f-1512-4460-ba86-f6dc96a7bf27
Diffstat (limited to 'make/build.xml')
-rwxr-xr-x | make/build.xml | 40 |
1 files changed, 38 insertions, 2 deletions
diff --git a/make/build.xml b/make/build.xml index 6ad5e4e..875d975 100755 --- a/make/build.xml +++ b/make/build.xml @@ -33,7 +33,21 @@ <property name="gluegen.excludes" value="com/sun/gluegen/runtime/BufferFactoryInternal.java,com/sun/gluegen/nativesig/**" /> </target> - <target name="init" depends="load.user.properties,setup-excludes-1,setup-excludes-2"> + <target name="init.javame.cdc.fp" if="isCDCFP"> + <property name="javac.bootclasspath.jar" value="lib/cdc_fp.jar" /> + </target> + + <target name="setup.javase" unless="isCDCFP"> + <copy file="../src/java/com/sun/gluegen/runtime/BufferFactory.java.javase" tofile="../build/gensrc/java/com/sun/gluegen/runtime/BufferFactory.java" /> + <copy file="../src/java/com/sun/gluegen/runtime/StructAccessor.java.javase" tofile="../build/gensrc/java/com/sun/gluegen/runtime/StructAccessor.java" /> + </target> + + <target name="setup.javame.cdc.fp" if="isCDCFP"> + <copy file="../src/java/com/sun/gluegen/runtime/BufferFactory.java.javame_cdc_fp" tofile="../build/gensrc/java/com/sun/gluegen/runtime/BufferFactory.java" /> + <copy file="../src/java/com/sun/gluegen/runtime/StructAccessor.java.javame_cdc_fp" tofile="../build/gensrc/java/com/sun/gluegen/runtime/StructAccessor.java" /> + </target> + + <target name="init" depends="load.user.properties,setup-excludes-1,setup-excludes-2,init.javame.cdc.fp"> <!-- Declare all paths and user defined variables. --> <!-- The source directories. --> @@ -54,6 +68,10 @@ <mkdir dir="${src.generated.java}" /> <mkdir dir="${classes}" /> + <!-- Set up compilation for either Java SE or Java ME / CDC / FP. --> + <antcall target="setup.javase" inheritRefs="true" /> + <antcall target="setup.javame.cdc.fp" inheritRefs="true" /> + <!-- Create the classpath for ANTLR. This requires the user-defined - "antlr.jar" property. --> <path id="antlr.classpath"> @@ -404,7 +422,25 @@ <!-- Build GlueGen using the generated Java files along with the - original source. --> - <javac destdir="${classes}" source="1.4" debug="true" debuglevel="source,lines" excludes="${gluegen.excludes}"> + <javac destdir="${classes}" + source="1.4" + debug="true" + debuglevel="source,lines" + excludes="${gluegen.excludes}"> + <src path="${src.java}" /> + <src path="${src.generated.java}" /> + <classpath refid="antlr.classpath" /> + </javac> + + <!-- Re-build just the gluegen-rt.jar classes using the Java ME + boot classes, if they're in use. --> + <delete dir="../build/classes/com/sun/gluegen/runtime" /> + <javac destdir="${classes}" + source="1.4" + debug="true" + debuglevel="source,lines" + excludes="${gluegen.excludes}" + bootclasspath="${javac.bootclasspath.jar}"> <src path="${src.java}" /> <src path="${src.generated.java}" /> <classpath refid="antlr.classpath" /> |