This is an automated email from the ASF dual-hosted git repository. jtulach pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/incubator-netbeans.git
commit 4b857cc95c5cb236427d7f488b61ef10c64a52de Author: Jaroslav Tulach <[email protected]> AuthorDate: Wed Jan 2 08:23:15 2019 +0100 Detect JDK9+ by presence of jmod --- .travis.yml | 2 +- nbbuild/build.xml | 7 ++++++- nbbuild/jdk.xml | 7 +++++-- nbi/engine/build.xml | 2 ++ platform/applemenu/build.xml | 4 +++- 5 files changed, 17 insertions(+), 5 deletions(-) diff --git a/.travis.yml b/.travis.yml index 85bbeb3..46b752c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -37,7 +37,7 @@ matrix: - env: SIGTEST=true COMPILETEST=false RAT=false EOL=true LICENSE=false CV=true RUN_TESTS_JDK8=false RUN_JAVA_TESTS=false jdk: oraclejdk8 - - env: OPTS="-quiet -Dpermit.jdk9.builds=true -Dvanilla.javac.exists=true" TARGET="build-platform" + - env: OPTS="-quiet" TARGET="build-platform" jdk: oraclejdk11 - env: SIGTEST=false COMPILETEST=false RAT=false EOL=false LICENSE=false CV=false RUN_TESTS_JDK9PLUS=false RUN_TESTS_JDK8=true TEST_MODULES="java/java.completion" OPTS="-Dcluster.config=java -quiet build -Djavac.compilerargs=-nowarn -Dbuild.compiler.deprecation=false" diff --git a/nbbuild/build.xml b/nbbuild/build.xml index 889f6bc..64fb35f 100644 --- a/nbbuild/build.xml +++ b/nbbuild/build.xml @@ -46,7 +46,10 @@ <fail message="You need JDK 8+ to build NetBeans; nbjdk.home=${nbjdk.home} java.home=${java.home}"> <condition> <not> - <isset property="have-jdk-1.8"/> + <or> + <isset property="have-jdk-1.8"/> + <isset property="have-jdk-1.9"/> + </or> </not> </condition> </fail> @@ -451,6 +454,8 @@ Hg ID: ${hg.id} <mkdir dir="${netbeans.dest.dir}"/> <ant dir="." target="-build-platform" inheritAll="false"> <property name="cluster.config" value="platform"/> + <property name="permit.jdk9.builds" value="true"/> + <property name="vanilla.javac.exists" value="true"/> </ant> </target> diff --git a/nbbuild/jdk.xml b/nbbuild/jdk.xml index 946871a..db47190 100644 --- a/nbbuild/jdk.xml +++ b/nbbuild/jdk.xml @@ -96,7 +96,10 @@ <available file="${nbjdk.javac}" type="file"/> <available file="${nbjdk.java}" type="file"/> <available file="${nbjdk.javadoc}" type="file"/> - <available classname="java.lang.Object" classpath="${nbjdk.bootclasspath}" ignoresystemclasses="true"/> + <or> + <available classname="java.lang.Object" classpath="${nbjdk.bootclasspath}" ignoresystemclasses="true"/> + <available file="${nbjdk.home}/bin/jmod"/> + </or> </and> </condition> <available property="have-jdk-1.4" classname="java.lang.CharSequence" classpath="${nbjdk.bootclasspath}" ignoresystemclasses="true"/> @@ -104,7 +107,7 @@ <available property="have-jdk-1.6" classname="java.util.ServiceLoader" classpath="${nbjdk.bootclasspath}" ignoresystemclasses="true"/> <available property="have-jdk-1.7" classname="java.lang.ReflectiveOperationException" classpath="${nbjdk.bootclasspath}" ignoresystemclasses="true"/> <available property="have-jdk-1.8" classname="java.lang.FunctionalInterface" classpath="${nbjdk.bootclasspath}" ignoresystemclasses="true"/> - <available property="have-jdk-1.9" classname="java.util.zip.CRC32C" classpath="${nbjdk.bootclasspath}" ignoresystemclasses="true"/> + <available property="have-jdk-1.9" file="${nbjdk.home}/bin/jmod"/> <echo level="verbose">nbjdk.active=${nbjdk.active} nbjdk.home=${nbjdk.home} nbjdk.java=${nbjdk.java} nbjdk.javac=${nbjdk.javac} nbjdk.javadoc=${nbjdk.javadoc} nbjdk.bootclasspath=${nbjdk.bootclasspath} nbjdk.valid=${nbjdk.valid} have-jdk-1.4=${have-jdk-1.4} have-jdk-1.5=${have-jdk-1.5} have-jdk-1.6=${have-jdk-1.6} have-jdk-1.7=${have-jdk-1.7} have-jdk-1.8=${have-jdk-1.8} have-jdk-1.9=${have-jdk-1.9}</echo> </target> diff --git a/nbi/engine/build.xml b/nbi/engine/build.xml index 2fb096e..69339e9 100644 --- a/nbi/engine/build.xml +++ b/nbi/engine/build.xml @@ -143,6 +143,8 @@ <target name="probe" depends="init"> <available property="probe.javac.source" value="1.6" classname="java.lang.Module"/> <available property="probe.javac.target" value="1.6" classname="java.lang.Module"/> + <available property="probe.javac.source" value="1.6" file="${nbjdk.home}/bin/jmod"/> + <available property="probe.javac.target" value="1.6" file="${nbjdk.home}/bin/jmod"/> <property name="probe.javac.source" value="1.3"/> <property name="probe.javac.target" value="1.1"/> <mkdir dir="${build.classes.dir}/org/netbeans/installer/utils/applications/"/> diff --git a/platform/applemenu/build.xml b/platform/applemenu/build.xml index bbed724..a72a0ab 100644 --- a/platform/applemenu/build.xml +++ b/platform/applemenu/build.xml @@ -28,7 +28,9 @@ <mkdir dir="${build.dir}/desktop-classes-src" /> <unzip src="external/applemenu-external-desktop-classes-8.2.zip" dest="${build.dir}/desktop-classes-src"/> <mkdir dir="${build.dir}/desktop-classes-classes" /> - <javac srcdir="${build.dir}/desktop-classes-src" destdir="${build.dir}/desktop-classes-classes" /> + <javac srcdir="${build.dir}/desktop-classes-src" destdir="${build.dir}/desktop-classes-classes" + source="1.8" target="1.8"> + </javac> </target> </project> --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected] For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
