Author: jfclere Date: Fri Feb 9 02:33:43 2007 New Revision: 505244 URL: http://svn.apache.org/viewvc?view=rev&rev=505244 Log: Don't add tools.jar if it is not existing.
Modified: tomcat/tc6.0.x/trunk/bin/setclasspath.sh Modified: tomcat/tc6.0.x/trunk/bin/setclasspath.sh URL: http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/bin/setclasspath.sh?view=diff&rev=505244&r1=505243&r2=505244 ============================================================================== --- tomcat/tc6.0.x/trunk/bin/setclasspath.sh (original) +++ tomcat/tc6.0.x/trunk/bin/setclasspath.sh Fri Feb 9 02:33:43 2007 @@ -68,8 +68,17 @@ JAVA_ENDORSED_DIRS="$BASEDIR"/endorsed # Set standard CLASSPATH +if [ "$1" = "javac" ] ; then + if [ ! -f "$JAVA_HOME"/lib/tools.jar ]; then + echo "Can't find tools.jar in JAVA_HOME" + echo "Need a JDK to run javac" + exit 1 + fi +fi if [ "$1" = "debug" -o "$1" = "javac" ] ; then - CLASSPATH="$JAVA_HOME"/lib/tools.jar + if [ -f "$JAVA_HOME"/lib/tools.jar ]; then + CLASSPATH="$JAVA_HOME"/lib/tools.jar + fi fi # OSX hack to CLASSPATH --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]