It seems Tomcat 4.1.19 up has a problem with paths that have spaces in them My tomcat directory is under Program File/Apache Group/Tomcat 4.1 I get the following error when I try to load a JSP org.apache.jasper.JasperException: Unable to compile class for JSP An error occurred at line: -1 in the jsp file: null Generated servlet error: [javac] Since fork is true, ignoring compiler setting. [javac] Compiling 1 source file [javac] Since fork is true, ignoring compiler setting. [javac] javac: invalid flag: C:\Program [javac] Usage: javac [javac] where possible options include: [javac] -g Generate all debugging info [javac] -g:none Generate no debugging info [javac] -g:{lines,vars,source} Generate only some debugging info [javac] -nowarn Generate no warnings [javac] -verbose Output messages about what the compiler is doing [javac] -deprecation Output source locations where deprecated APIs are used [javac] -classpath Specify where to find user class files [javac] -sourcepath Specify where to find input source files [javac] -bootclasspath Override location of bootstrap class files [javac] -extdirs Override location of installed extensions [javac] -d Specify where to place generated class files [javac] -encoding Specify character encoding used by source files [javac] -source Provide source compatibility with specified release [javac] -target Generate class files for specific VM version [javac] -help Print a synopsis of standard options I reported a similar bug with 4.1.19 I am using 4.1.24LE for JDK 1.4 and JDK 1.4 (obviously) Regards Steve
This clearly works fine for me (installer to default location, open the welcome page and JSP examples). You need to add info to reproduce (but you won't be able to).
I have experienced this and have tracked it down to a problem in Ant. It is triggered by (a) a long javac command line, usually caused by long paths to a lib directory with lots of jars in it, combined with (b) spaces in the path to the Tomcat directory (more specifically to the work directory within the Tomcat directory). The problem is documented in Ant bug 10499.
A duplicate was filed since; a (reported) possible workaround is to set the "fork" init-param of the Jasper servlet to "false".
Hi Tomcat developers, the next ant nightly build (http://cvs.apache.org/builds/ant/nightly/2003-06-04) contains a fix for the bug 10499 see http://nagoya.apache.org/bugzilla/show_bug.cgi?id=10499 This might solve this issue too. Individual users might want to patch their ant.jar or replace it with the one of the nightly build if they are affected by this problem.