Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

error - unable to compile class for jsp

 
Santosh sab
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi
I am using tomcat 5.0.30 and j2re1.4.1_01
i am getting following error whenever request is forwarded to jsp






In the java properties of tomcat i am having following path in the classpath field - C:\Program Files\Java\j2re1.4.1_01\lib\tools.jar;C:\Program Files\Apache Software Foundation\Tomcat 5.0\bin\bootstrap.jar



I checked the tools.jar file in the above mentioned path and it contains MAIN class in com.sun.tools.javac folder

Kindly tell me where to make changes so that the jsp gets compiled
 
William Brogden
Author and all-around good cowpoke
Rancher
Posts: 13071
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Does the value of JAVA_HOME in your environment point to
C:\Program Files\Java\j2re1.4.1_01

Tomcat totally ignores the CLASSPATH environment variable.

See the class-loader-howto.html file under tomcat-docs in a typical Tomcat installation for more about how Tomcat looks for classes.

Bill
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"santosh248",
Welcome to JavaRanch!

We're pleased to have you here with us in the Tomcat forum, but there
are a few rules that need to be followed, and one is that proper names are
required. Please take a look at the
JavaRanch Naming Policy and
adjust your display name to match it.

In particular, your display name must be a first and a last name separated by a space character, and must not be obviously fictitious.

You can change it here




Tomcat 5.0 and lower requires a full JDK (j2sdk) in order to compile JSPs.
Starting with 5.5, Tomcat ships with it's own compiler and can run with only a JRE.

Install a full JDK and make sure your JAVA_HOME environment variable points to it.

[ April 27, 2007: Message edited by: Ben Souther ]
[ April 27, 2007: Message edited by: Ben Souther ]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic