Changeset 30106 for main/trunk/gli


Ignore:
Timestamp:
2015-08-13T20:33:28+12:00 (9 years ago)
Author:
ak19
Message:

HINT for search4j adjusted after JRE inclusion on Mac Lion.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/trunk/gli/findjava.sh

    r29010 r30106  
    6767
    6868    # Give search4j a hint to find Java depending on the platform
    69     if [ "$GSDLOS" = "linux" ]; then
    70     HINT=`cd "$GSDLHOME";pwd`/packages/jre
    71     elif [ "$GSDLOS" = "darwin" ]; then
    72     # http://java.dzone.com/articles/java-findingsetting
     69    # we now include a JRE with Mac (Mountain) Lion, because from Yosemite onwards there's no system Java on Macs
     70    HINT=`cd "$GSDLHOME";pwd`/packages/jre   
     71   
     72    # we can't use boolean operator -a to do the AND, since it doesn't "short-circuit" if the first test fails
     73    # see http://www.tldp.org/LDP/abs/html/comparison-ops.html
     74    if [ "$GSDLOS" = "darwin" ] && [ ! -d "$HINT" ]; then
     75        # http://java.dzone.com/articles/java-findingsetting
    7376    # explains that /usr/libexec/java_home will print the default JDK
    7477    # regardless of which Mac OS we're on. Tested on Maverick, Lion, Leopard
    7578    # (run `/usr/libexec/java_home -v 1.7` to find a specific version)
    7679    HINT=`/usr/libexec/java_home`
    77     fi 
     80    fi
    7881   
    7982    javapath="`"$SEARCH4J_EXECUTABLE" -e -p "$HINT" -m $MINIMUM_JAVA_VERSION`"
Note: See TracChangeset for help on using the changeset viewer.