Changeset 30106
- Timestamp:
- 2015-08-13T20:33:28+12:00 (8 years ago)
- Location:
- main/trunk
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
main/trunk/gli/findjava.sh
r29010 r30106 67 67 68 68 # 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 73 76 # explains that /usr/libexec/java_home will print the default JDK 74 77 # regardless of which Mac OS we're on. Tested on Maverick, Lion, Leopard 75 78 # (run `/usr/libexec/java_home -v 1.7` to find a specific version) 76 79 HINT=`/usr/libexec/java_home` 77 fi 80 fi 78 81 79 82 javapath="`"$SEARCH4J_EXECUTABLE" -e -p "$HINT" -m $MINIMUM_JAVA_VERSION`" -
main/trunk/greenstone3/gs3-server.sh
r27873 r30106 104 104 # JRE_HOME or JAVA_HOME must be set correctly to run this program 105 105 HINT="`pwd`/packages/jre" 106 if [ "$GSDLOS" = "darwin" ] && [ ! -d "$HINT" ]; then 107 HINT=`/usr/libexec/java_home` 108 fi 106 109 javapath=`search4j -p "$HINT" -m $java_min_version -e` 107 110 if [ "$?" == "0" ]; then -
main/trunk/greenstone3/gs3-setup.sh
r26795 r30106 179 179 function checkJava() { 180 180 181 # we now include a JRE with Mac (Mountain) Lion too, because from Yosemite onwards there's no system Java on Macs 181 182 HINT="`pwd`/packages/jre" 182 if [ $GSDLOS = darwin ]; then 183 HINT=/System/Library/Frameworks/JavaVM.framework/Home 183 if [ "$GSDLOS" = "darwin" ] && [ ! -d "$HINT" ]; then 184 HINT=`/usr/libexec/java_home` 185 # old code used as fallback: 186 if [ ! -d "$HINT" ]; then 187 HINT=/System/Library/Frameworks/JavaVM.framework/Home 188 fi 184 189 fi 185 190 … … 188 193 FOUNDJAVAHOME="`bin/search4j -p \"$HINT\" -m $java_min_version`" 189 194 if [ "$?" == "0" ]; then 190 #found a suit ible java195 #found a suitable java 191 196 setupJavaAt "$FOUNDJAVAHOME" 192 197 else
Note:
See TracChangeset
for help on using the changeset viewer.