aboutsummaryrefslogtreecommitdiffstats
path: root/build.xml
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2013-06-27 16:39:53 +0200
committerSven Gothel <[email protected]>2013-06-27 16:39:53 +0200
commit4c41e7d4286d3ce1f3ef7c8e920ec3cca99e67b8 (patch)
tree7e7643ff77eabb703a089f01a02407c2015b7bd1 /build.xml
parent5611eeb867e0268ee10248d98a3845eb9b0971d1 (diff)
Ant build.xml: Build target is 1.6; Pick up TARGET_RT_JAR (-> JRE 1.6 rt.jar); Respect javacdebug* props, def. is none.
Diffstat (limited to 'build.xml')
-rw-r--r--build.xml24
1 files changed, 23 insertions, 1 deletions
diff --git a/build.xml b/build.xml
index f61b640..e2547d8 100644
--- a/build.xml
+++ b/build.xml
@@ -1,5 +1,6 @@
<!-- Buildfile -->
<project name="jake2" default="usage" basedir=".">
+ <property environment="env" />
<taskdef name="proguard" classname="proguard.ant.ProGuardTask">
<classpath>
@@ -18,6 +19,25 @@
<property name="build" location="build"/>
<property name="dist" location="dist"/>
+ <property name="javacdebug" value="false" />
+ <property name="javacdebuglevel" value="" />
+
+ <condition property="target.rt.jar" value="${env.TARGET_RT_JAR}">
+ <not>
+ <equals arg1="${env.TARGET_RT_JAR}" arg2="$${env.TARGET_RT_JAR}" casesensitive="true" />
+ </not>
+ </condition>
+ <!-- Default value for std Java (incl. Java7 on OS X) -->
+ <condition property="target.rt.jar"
+ value="${java.home}/lib/rt.jar">
+ <available file="${java.home}/lib/rt.jar"/>
+ </condition>
+ <!-- Default fallback value for Java6 OS X -->
+ <condition property="target.rt.jar"
+ value="${java.home}/../Classes/classes.jar">
+ <available file="${java.home}/../Classes/classes.jar"/>
+ </condition>
+
<!-- different classpaths -->
<path id="build.class.path">
<pathelement location="lib/jogamp/gluegen-rt.jar"/>
@@ -48,7 +68,9 @@
<!-- compile -->
<target name="compile" depends="init">
- <javac destdir="${build}" optimize="on" debug="off" source="1.6">
+ <javac destdir="${build}"
+ source="1.6" target="1.6" bootclasspath="${target.rt.jar}"
+ debug="${javacdebug}" debuglevel="${javacdebuglevel}">
<src path="${src}"/>
<include name="jake2/**"/>
<classpath refid="build.class.path"/>