[PATCH libvirt-java] Set source and target version to Java 1.6

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On platforms with Java 1.7 it will still produce compatible code
with Java 1.6 platforms

Java 1.6 is still out there and widely used.

Signed-off-by: Wido den Hollander <wido@xxxxxxxxx>
---
 build.properties |    2 ++
 build.xml        |    4 ++--
 2 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/build.properties b/build.properties
index 679a271..7721f90 100644
--- a/build.properties
+++ b/build.properties
@@ -2,5 +2,7 @@ version=0.5.0
 release=1
 libvirt.required=0.9.12
 java.required=1:1.5.0
+java.target=1.6
+java.source=1.6
 rpm.topdir=/home/veillard/rpms
 jar.dir=/usr/share/java
diff --git a/build.xml b/build.xml
index 61b15bb..acd9c92 100644
--- a/build.xml
+++ b/build.xml
@@ -52,7 +52,7 @@
 				destdir="target/testclasses"
 				cache="target/cache"
 				closure="true" />
-		<javac srcdir="src/test/java" debug="${javac.debug}" includes="**/*.java" classpathref="test.classpath" destdir="target/testclasses" includeAntRuntime="false" />
+		<javac srcdir="src/test/java" debug="${javac.debug}" source="${java.source}" target="${java.target}" includes="**/*.java" classpathref="test.classpath" destdir="target/testclasses" includeAntRuntime="false" />
 	</target>
 
 	<target name="build" depends="init" description="builds the code">
@@ -60,7 +60,7 @@
 				destdir="target/classes"
 				cache="target/cache"
 				closure="true" />
-		<javac srcdir="src/main/java" debug="${javac.debug}" includes="**/*.java" classpathref="compile.classpath" destdir="target/classes" includeAntRuntime="false" />
+		<javac srcdir="src/main/java" debug="${javac.debug}" source="${java.source}" target="${java.target}" includes="**/*.java" classpathref="compile.classpath" destdir="target/classes" includeAntRuntime="false" />
 	</target>
 
 	<target name="test" depends="buildtests" description="tests the code">
-- 
1.7.9.5

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]