BugRat Report # 697

Project: Tomcat Release: Tomcat 3.2
Category: Feature Requests SubCategory: Enhancement
Class: suggest State: received
Priority: medium Severity: non-critical
Confidence: public

Submitter: _Anonymous ( anonymous-bug@cortexity.com )
Date Submitted: Jan 4 2001, 01:52:50 CST
Responsible: Z_Tomcat Alias ( tomcat-bugs@cortexity.com )

Synopsis:
If TOMCAT_HOME is already set by user, bin/tomcat.bat should behave more like bin/tomcat.sh
Environment: (jvm, os, osrel, platform)
NA, Windows, 2000, Intel

Additional Environment Description:

Report Description:
If the TOMCAT_HOME environment variable is already set by the user before tomcat.bat is run, tomcat.bat should respect that decision and move forward w/o quitting, even if lib/servlet.jar doesn't exist. Now, why would you want this? Namely to have the tomcat libs located in an entirely separate directory structure from the content. Unix allows this assuming you set your TOMCAT_HOME and CLASSPATH before calling tomcat.sh. Windows should behave the same. Here is how I modified tomcat.bat: Original line 43 onward: if not "%TOMCAT_HOME%" == "" goto gotTomcatHome set TOMCAT_HOME=. :gotTomcatHome if exist "%TOMCAT_HOME%\lib\servlet.jar" goto okTomcatHome echo Unable to locate servlet.jar, check the value of TOMCAT_HOME. goto cleanup :okTomcatHome My proposed changes: if not "%TOMCAT_HOME%" == "" goto gotTomcatHome set TOMCAT_HOME=. :gotTomcatHome if exist "%TOMCAT_HOME%\lib\servlet.jar" goto okTomcatHome rem If TOMCAT_HOME does exist, assume that the user knows what they are doing. rem Beware that if the user does not set the CLASSPATH themselves, that rem Tomcat will most likely fail to start. if not "%TOMCAT_HOME%" == "" goto okTomcatHome echo Unable to locate servlet.jar, check the value of TOMCAT_HOME. goto cleanup :okTomcatHome For more info, please contact Mark Manca at mmanca@adobe.com.

View this report online...