< prev index next >

common/autoconf/boot-jdk.m4

Print this page


   1 #
   2 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved.
   3 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4 #
   5 # This code is free software; you can redistribute it and/or modify it
   6 # under the terms of the GNU General Public License version 2 only, as
   7 # published by the Free Software Foundation.  Oracle designates this
   8 # particular file as subject to the "Classpath" exception as provided
   9 # by Oracle in the LICENSE file that accompanied this code.
  10 #
  11 # This code is distributed in the hope that it will be useful, but WITHOUT
  12 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  13 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  14 # version 2 for more details (a copy is included in the LICENSE file that
  15 # accompanied this code).
  16 #
  17 # You should have received a copy of the GNU General Public License version
  18 # 2 along with this work; if not, write to the Free Software Foundation,
  19 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  20 #
  21 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  22 # or visit www.oracle.com if you need additional information or have any


 206     VIRTUAL_DIR="[$]$1/Java"
 207     BASIC_WINDOWS_REWRITE_AS_UNIX_PATH(VIRTUAL_DIR)
 208     BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY($VIRTUAL_DIR)
 209   fi
 210 ])
 211 
 212 # Test: Is there a JDK installed in default, well-known locations?
 213 AC_DEFUN([BOOTJDK_CHECK_WELL_KNOWN_LOCATIONS],
 214 [
 215   if test "x$OPENJDK_TARGET_OS" = xwindows; then
 216     BOOTJDK_DO_CHECK([BOOTJDK_FIND_BEST_JDK_IN_WINDOWS_VIRTUAL_DIRECTORY([ProgramW6432])])
 217     BOOTJDK_DO_CHECK([BOOTJDK_FIND_BEST_JDK_IN_WINDOWS_VIRTUAL_DIRECTORY([PROGRAMW6432])])
 218     BOOTJDK_DO_CHECK([BOOTJDK_FIND_BEST_JDK_IN_WINDOWS_VIRTUAL_DIRECTORY([PROGRAMFILES])])
 219     BOOTJDK_DO_CHECK([BOOTJDK_FIND_BEST_JDK_IN_WINDOWS_VIRTUAL_DIRECTORY([ProgramFiles])])
 220     BOOTJDK_DO_CHECK([BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY([/cygdrive/c/Program Files/Java])])
 221   elif test "x$OPENJDK_TARGET_OS" = xmacosx; then
 222     BOOTJDK_DO_CHECK([BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY([/Library/Java/JavaVirtualMachines],[/Contents/Home])])
 223     BOOTJDK_DO_CHECK([BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY([/System/Library/Java/JavaVirtualMachines],[/Contents/Home])])
 224   elif test "x$OPENJDK_TARGET_OS" = xlinux; then
 225     BOOTJDK_DO_CHECK([BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY([/usr/lib/jvm])])



 226   fi
 227 ])
 228 
 229 # Check that a command-line tool in the Boot JDK is correct
 230 # $1 = name of variable to assign
 231 # $2 = name of binary
 232 AC_DEFUN([BOOTJDK_CHECK_TOOL_IN_BOOTJDK],
 233 [
 234   # Use user overridden value if available, otherwise locate tool in the Boot JDK.
 235   BASIC_SETUP_TOOL($1,
 236     [
 237       AC_MSG_CHECKING([for $2 in Boot JDK])
 238       $1=$BOOT_JDK/bin/$2
 239       if test ! -x [$]$1; then
 240         AC_MSG_RESULT(not found)
 241         AC_MSG_NOTICE([Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk])
 242         AC_MSG_ERROR([Could not find $2 in the Boot JDK])
 243       fi
 244       AC_MSG_RESULT(ok)
 245       AC_SUBST($1)


   1 #
   2 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved.
   3 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4 #
   5 # This code is free software; you can redistribute it and/or modify it
   6 # under the terms of the GNU General Public License version 2 only, as
   7 # published by the Free Software Foundation.  Oracle designates this
   8 # particular file as subject to the "Classpath" exception as provided
   9 # by Oracle in the LICENSE file that accompanied this code.
  10 #
  11 # This code is distributed in the hope that it will be useful, but WITHOUT
  12 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  13 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  14 # version 2 for more details (a copy is included in the LICENSE file that
  15 # accompanied this code).
  16 #
  17 # You should have received a copy of the GNU General Public License version
  18 # 2 along with this work; if not, write to the Free Software Foundation,
  19 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  20 #
  21 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  22 # or visit www.oracle.com if you need additional information or have any


 206     VIRTUAL_DIR="[$]$1/Java"
 207     BASIC_WINDOWS_REWRITE_AS_UNIX_PATH(VIRTUAL_DIR)
 208     BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY($VIRTUAL_DIR)
 209   fi
 210 ])
 211 
 212 # Test: Is there a JDK installed in default, well-known locations?
 213 AC_DEFUN([BOOTJDK_CHECK_WELL_KNOWN_LOCATIONS],
 214 [
 215   if test "x$OPENJDK_TARGET_OS" = xwindows; then
 216     BOOTJDK_DO_CHECK([BOOTJDK_FIND_BEST_JDK_IN_WINDOWS_VIRTUAL_DIRECTORY([ProgramW6432])])
 217     BOOTJDK_DO_CHECK([BOOTJDK_FIND_BEST_JDK_IN_WINDOWS_VIRTUAL_DIRECTORY([PROGRAMW6432])])
 218     BOOTJDK_DO_CHECK([BOOTJDK_FIND_BEST_JDK_IN_WINDOWS_VIRTUAL_DIRECTORY([PROGRAMFILES])])
 219     BOOTJDK_DO_CHECK([BOOTJDK_FIND_BEST_JDK_IN_WINDOWS_VIRTUAL_DIRECTORY([ProgramFiles])])
 220     BOOTJDK_DO_CHECK([BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY([/cygdrive/c/Program Files/Java])])
 221   elif test "x$OPENJDK_TARGET_OS" = xmacosx; then
 222     BOOTJDK_DO_CHECK([BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY([/Library/Java/JavaVirtualMachines],[/Contents/Home])])
 223     BOOTJDK_DO_CHECK([BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY([/System/Library/Java/JavaVirtualMachines],[/Contents/Home])])
 224   elif test "x$OPENJDK_TARGET_OS" = xlinux; then
 225     BOOTJDK_DO_CHECK([BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY([/usr/lib/jvm])])
 226   elif test "x$OPENJDK_TARGET_OS" = xbsd; then
 227     BOOTJDK_DO_CHECK([BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY([/usr/pkg/java])])
 228     BOOTJDK_DO_CHECK([BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY([/usr/local])])
 229   fi
 230 ])
 231 
 232 # Check that a command-line tool in the Boot JDK is correct
 233 # $1 = name of variable to assign
 234 # $2 = name of binary
 235 AC_DEFUN([BOOTJDK_CHECK_TOOL_IN_BOOTJDK],
 236 [
 237   # Use user overridden value if available, otherwise locate tool in the Boot JDK.
 238   BASIC_SETUP_TOOL($1,
 239     [
 240       AC_MSG_CHECKING([for $2 in Boot JDK])
 241       $1=$BOOT_JDK/bin/$2
 242       if test ! -x [$]$1; then
 243         AC_MSG_RESULT(not found)
 244         AC_MSG_NOTICE([Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk])
 245         AC_MSG_ERROR([Could not find $2 in the Boot JDK])
 246       fi
 247       AC_MSG_RESULT(ok)
 248       AC_SUBST($1)


< prev index next >