ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Scott Francis" <scott.fran...@newisys.com>
Subject RE: java.lang.NoClassDefFoundError: org/apache/jasper/JspC
Date Mon, 24 Jun 2002 16:40:19 GMT
That's actually probably exactly it as I have seen the same issue with Microsoft Visual C++
link lines. I know this is a problem in the 95/98/Me world (not sure about the NT plats)...but
Windows has a limit on how many characters it can have in a single line (the actual number
escapes me).  But the long and the short of it is if you have enormously long file paths that
are all being referenced in a single line such as a link line or classpath, Microsoft will
eventually just truncate them at its limit.

Yes, another reason to thank Ol' Bill for creating such a swell environment and insisting
on making pretty interfaces instead of fixing the background guts.

Scott

-----Original Message-----
From: Geoff Meakin [mailto:geoffm@isocra.com]
Sent: Monday, June 24, 2002 11:36 AM
To: Ant Users List
Subject: RE: java.lang.NoClassDefFoundError: org/apache/jasper/JspC


This is a bit of a wild-goose-chase sort of response, but I've had a similar
problem, and resolved it down to the
fact that although the correct jars were in the classpath, the classpath was
somehow "too long" for the VM,
and some jars didn't get picked up. Just in case this is an issue on your
machine, you could try (as a test only) copying all the jars you need into a
directory such as D:\l and make your classpath much shorter.

I doubt if it is this, but I spent the best part of a day scratching my head
before I found that out..

Cheers
-Geoff


-----Original Message-----
From: Dave Gibbs [mailto:dgibbs@agency.com]
Sent: 24 June 2002 05:15 PM
To: ant-user@jakarta.apache.org
Subject: java.lang.NoClassDefFoundError: org/apache/jasper/JspC


I hope some-one has solved this no-doubt simple problem,

I am trying to use the jspc optional task and get the following error.

"[java] java.lang.NoClassDefFoundError: org/apache/jasper/JspC
[java] Exception in thread "main"

I am using 1.5Beta3. I have the distributed "optional.jar" in the lib
directory. I have copied "jasper-runtime.jar" and "jasper-compiler.jar" to
the lib directory.

The LOCALCLASSPATH echoed from the ant.bat is as follows

"D:\jdk1.3.1_03\lib\tools.jar;D:\jakarta-ant-1.5Beta3\lib\xml-apis.jar;D:\ja
karta-ant-1.5Beta3\lib\xercesImpl.jar;D:\jakarta-ant-1.5Beta3\lib\optional.j
ar;D:\jakarta-ant-1.5Beta3\lib\jasper-runtime.jar;D:\jakarta-ant-1.5Beta3\li
b\jasper-compiler.jar;D:\jakarta-ant-1.5Beta3\lib\ant.jar;.;C:\Program
Files\Apache Group\Tomcat 4.1\common\endorsed\xercesImpl.jar;C:\Program
Files\Apache Group\Tomcat
4.1\common\endorsed\xmlParserAPIs.jar;D:\DB2\java\db2java.zip;D:\DB2\java\ru
ntime.zip;D:\DB2\java\sqlj.zip;D:\DB2\bin;C:\Documents and
Settings\dgibbs\My
Documents\work\shop_prototype\lib\j2ee.jar;D:\jakarta-log4j-1.2\dist\lib\log
4j-1.2.jar;"

There is some duplication in there because I have been trashing a bit
tragically at this problem.

Do y'all believe the error to be as reported  or could it be some further
dependency ? As a reality check I have been trying to run jspc.bat from the
tomcat 4.1 distribution and am getting a similarly inexplicable
NoClassDefFoundError for "org/xml/sax/SAXException". I'm a bit puzzled since
this class is distributed in "..\common\endorsed\xmlParserAPIs.jar".
Is it something to do with the uninitialised property
-Djava.endorsed.dirs="%JAVA_ENDORSED_DIRS%"
which I find in the jasper.bat file ? I'm not sure about the meaning if the
"endorsed directories".

I'd be very grateful if some-one who has worked through this could help.
btw.. JAVA_HOME, ANT_HOME, CATALINA_HOME, JASPER_HOME environment variables
all appear to be correctly set.

Dave


--
To unsubscribe, e-mail:   <mailto:ant-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-user-help@jakarta.apache.org>



--
To unsubscribe, e-mail:   <mailto:ant-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-user-help@jakarta.apache.org>


--
To unsubscribe, e-mail:   <mailto:ant-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-user-help@jakarta.apache.org>


Mime
View raw message