DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT <http://issues.apache.org/bugzilla/show_bug.cgi?id=32081>. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=32081 Wrapper scripts require a JDK to be present. Summary: Wrapper scripts require a JDK to be present. Product: Tomcat 5 Version: 5.5.4 Platform: All OS/Version: All Status: NEW Severity: Normal Priority: Other Component: Native:Integration AssignedTo: [EMAIL PROTECTED] ReportedBy: [EMAIL PROTECTED] A distribution as-is will not run with a JRE. This is because wrapper scripts look for executables associated with a JDK such as jdb etc, as well as java. These occur in the files $CATALINA_HOME/bin/setclasspath.bat and $CATALINA_HOME/bin/setclasspath.sh. The following patches alter these scripts in the following way: 1) they only look for the required files associated with a JRE, e.g. java. 2) if not found, the message has been changed to say that JAVA_HOME should point to a JDK or a JRE. Here is a patch for $CATALINA_HOME/bin/setclasspath.bat: --- setclasspath.bat Fri Oct 29 20:13:00 2004 +++ setclasspath2.bat Fri Nov 5 10:57:56 2004 @@ -12,13 +12,11 @@ :gotJavaHome if not exist "%JAVA_HOME%\bin\java.exe" goto noJavaHome if not exist "%JAVA_HOME%\bin\javaw.exe" goto noJavaHome -if not exist "%JAVA_HOME%\bin\jdb.exe" goto noJavaHome -if not exist "%JAVA_HOME%\bin\javac.exe" goto noJavaHome goto okJavaHome :noJavaHome echo The JAVA_HOME environment variable is not defined correctly echo This environment variable is needed to run this program -echo NB: JAVA_HOME should point to a JDK not a JRE +echo NB: JAVA_HOME should point to a JDK or a JRE goto exit :okJavaHome @@ -55,3 +53,4 @@ exit /b 1 :end + Here is a patch for $CATALINA_HOME/bin/setclasspath.sh --- setclasspath.sh Fri Oct 29 20:13:00 2004 +++ setclasspath2.sh Fri Nov 5 12:22:55 2004 @@ -18,10 +18,10 @@ exit 1 fi else - if [ ! -x "$JAVA_HOME"/bin/java -o ! -x "$JAVA_HOME"/bin/jdb -o ! -x "$JAVA_HOME"/bin/javac ]; then + if [ ! -x "$JAVA_HOME"/bin/java ]; then echo "The JAVA_HOME environment variable is not defined correctly" echo "This environment variable is needed to run this program" - echo "NB: JAVA_HOME should point to a JDK not a JRE" + echo "NB: JAVA_HOME should point to a JDK or a JRE" exit 1 fi fi @@ -59,3 +59,4 @@ _RUNJDB="$JAVA_HOME"/bin/jdb fi _RUNJAVAC="$JAVA_HOME"/bin/javac + --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]