Author: remy.maucherat(a)jboss.com
Date: 2007-10-18 12:45:38 -0400 (Thu, 18 Oct 2007)
New Revision: 313
Modified:
trunk/bin/setclasspath.sh
Log:
- Use /usr as the default JRE path if it's empty and /usr/bin/java exists.
- Interim patch until JF comes up with something better.
Modified: trunk/bin/setclasspath.sh
===================================================================
--- trunk/bin/setclasspath.sh 2007-10-16 15:22:11 UTC (rev 312)
+++ trunk/bin/setclasspath.sh 2007-10-18 16:45:38 UTC (rev 313)
@@ -14,9 +14,13 @@
if $darwin && [ -d
"/System/Library/Frameworks/JavaVM.framework/Versions/1.5/Home" ]; then
export
JAVA_HOME="/System/Library/Frameworks/JavaVM.framework/Versions/1.5/Home"
else
- echo "Neither the JAVA_HOME nor the JRE_HOME environment variable is
defined"
- echo "At least one of these environment variable is needed to run this
program"
- exit 1
+ if [ ! -x /usr/bin/java ]; then
+ echo "Neither the JAVA_HOME nor the JRE_HOME environment variable is
defined"
+ echo "At least one of these environment variable is needed to run this
program"
+ exit 1
+ else
+ JRE_HOME=/usr
+ fi
fi
fi
if [ -z "$JAVA_HOME" -a "$1" = "debug" ]; then
Show replies by date