Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

NoClassDefFoundError

Status
Not open for further replies.

tomhughes

Vendor
Aug 8, 2001
233
0
0
US
Does anyone know what this means, and how to correct it? This is what I got when I ran the JBuilder 7.0 tutorial for developing a JSP.

javax.servlet.ServletException: sun/tools/javac/Main


root cause
java.lang.NoClassDefFoundError: sun/tools/javac/Main
 
seems you didn't copy rt.jar from your JRE lib directory to the Tomcat root (or lib, I keep forgetting) directory.
As a result Tomcat cannot find the compiler it needs to transform the precompiled JSPs (now Java sources) into compiled Servlets.
 
I've got similar problem as follws when I am trying to build the web module:
"input.jsp": java.lang.NoClassDefFoundError javax/servlet/jsp/el/VariableResolver

I looked at the classpath in project property, rt.jar is included.

Thanks in advance for any help.
 
Don't think the javax/servlet... classes are in the rt.jar

I've done this in JBuilderX and the project included the servlet.jar (from the Tomcat installation bundled with JBX) on the classpath. Don't know where JB7 gets it from though.

Tim
---------------------------
"Your morbid fear of losing,
destroys the lives you're using." - Ozzy
 
You probably didn't include the correct JSTL version in your webmodule.
If your webmodule configuration is correct it will find the class.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top