You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by br...@apache.org on 2015/04/24 06:43:37 UTC
svn commit: r1675774 - /subversion/trunk/build/ac-macros/java.m4
Author: brane
Date: Fri Apr 24 04:43:37 2015
New Revision: 1675774
URL: http://svn.apache.org/r1675774
Log:
Be smarter about finding the JDK on OSX.
Without this change, we'll tend to find original 1.6 JDK on newer
versions of OSX instead of the latest and/or default.
* build/ac-macros/java.m4
(SVN_FIND_JDK): Check the output of the /usr/libexec/java_home
program that's the canonical way of locating the JDK on OSX.
Modified:
subversion/trunk/build/ac-macros/java.m4
Modified: subversion/trunk/build/ac-macros/java.m4
URL: http://svn.apache.org/viewvc/subversion/trunk/build/ac-macros/java.m4?rev=1675774&r1=1675773&r2=1675774&view=diff
==============================================================================
--- subversion/trunk/build/ac-macros/java.m4 (original)
+++ subversion/trunk/build/ac-macros/java.m4 Fri Apr 24 04:43:37 2015
@@ -62,10 +62,13 @@ AC_DEFUN(SVN_FIND_JDK,
JDK_SUITABLE=no
AC_MSG_CHECKING([for JDK])
if test $where = check; then
- dnl Prefer /Library/Java/Home first to try to be nice on Darwin.
- dnl We'll correct later if we get caught in the tangled web of JAVA_HOME.
+ dnl Prefer /usr/libexec/java_home, then /Library/Java/Home first
+ dnl to try to be nice on Darwin. We'll correct later if we get
+ dnl caught in the tangled web of JAVA_HOME.
if test -x "$JAVA_HOME/bin/java"; then
JDK="$JAVA_HOME"
+ elif test -x "/usr/libexec/java_home"; then
+ JDK=`/usr/libexec/java_home`
elif test -x "/Library/Java/Home/bin/java"; then
JDK="/Library/Java/Home"
elif test -x "/usr/bin/java"; then