common/autoconf/boot-jdk.m4
changeset 37014 da8d0d4aa7ea
parent 36506 17612cee3530
child 37659 3715a97ba87b
equal deleted inserted replaced
37011:c84d0cce090e 37014:da8d0d4aa7ea
   303 
   303 
   304   # When compiling code to be executed by the Boot JDK, force jdk8 compatibility.
   304   # When compiling code to be executed by the Boot JDK, force jdk8 compatibility.
   305   BOOT_JDK_SOURCETARGET="-source 8 -target 8"
   305   BOOT_JDK_SOURCETARGET="-source 8 -target 8"
   306   AC_SUBST(BOOT_JDK_SOURCETARGET)
   306   AC_SUBST(BOOT_JDK_SOURCETARGET)
   307 
   307 
   308   ADD_JVM_ARG_IF_OK([-Xpatch:], dummy, [$JAVA])
   308   ADD_JVM_ARG_IF_OK([-Xpatch:foo=bar], dummy, [$JAVA])
   309   AC_MSG_CHECKING([if Boot JDK supports modules])
   309   AC_MSG_CHECKING([if Boot JDK supports modules])
   310   if test "x$JVM_ARG_OK" = "xtrue"; then
   310   if test "x$JVM_ARG_OK" = "xtrue"; then
   311     AC_MSG_RESULT([yes])
   311     AC_MSG_RESULT([yes])
   312     BOOT_JDK_MODULAR="true"
   312     BOOT_JDK_MODULAR="true"
   313   else
   313   else
   442       else
   442       else
   443         # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
   443         # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
   444         BUILD_JDK_VERSION=`"$BUILD_JDK/bin/java" -version 2>&1 | head -n 1`
   444         BUILD_JDK_VERSION=`"$BUILD_JDK/bin/java" -version 2>&1 | head -n 1`
   445 
   445 
   446         # Extra M4 quote needed to protect [] in grep expression.
   446         # Extra M4 quote needed to protect [] in grep expression.
   447         [FOUND_CORRECT_VERSION=`echo $BUILD_JDK_VERSION | grep  '\"1\.[9]\.'`]
   447         [FOUND_CORRECT_VERSION=`echo $BUILD_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"'`]
   448         if test "x$FOUND_CORRECT_VERSION" = x; then
   448         if test "x$FOUND_CORRECT_VERSION" = x; then
   449           AC_MSG_NOTICE([Potential Boot JDK found at $BUILD_JDK is incorrect JDK version ($BUILD_JDK_VERSION); ignoring])
   449           AC_MSG_NOTICE([Potential Build JDK found at $BUILD_JDK is incorrect JDK version ($BUILD_JDK_VERSION); ignoring])
   450           AC_MSG_NOTICE([(Your Build JDK must be version 9)])
   450           AC_MSG_NOTICE([(Your Build JDK must be version 9)])
   451           BUILD_JDK_FOUND=no
   451           BUILD_JDK_FOUND=no
   452         else
   452         else
   453           # We're done!
   453           # We're done!
   454           BUILD_JDK_FOUND=yes
   454           BUILD_JDK_FOUND=yes