ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Manuel Mall>
Subject NoClassDefFoundError exception on when <taskdef> is invoked a sec ond time
Date Thu, 11 Dec 2003 03:46:36 GMT
I have a buildfile a.xml which calls b.xml through an <ant> task a
number of times. b.xml contains a <taskdef> which contains a nested

On the first invocation of b.xml through the <ant> task in a.xml
everything works fine. However, the second time around I get a
NoClassDefFoundError exception on the <taskdef> in b.xml. 

I am not sure what I might be doing wrong here. 


Some more info:
I am using ant 1.5.4..

The abbreviated ant output is:
jspc: <-- this is the first invocation of b.xml
     [echo] Precompiling application internet from
/data01/oscar/internet/htdocs using tomcat in
    [javac] Compiling 103 source files to
jspc:  <-- this is the second invocation of b.xml
     [echo] Precompiling application intranet from
/data01/oscar/intranet/htdocs using tomcat in

file:/home/mm/oscar/build_current/b.xml:37: Could not create task of
type: jasper2 due to java.lang.NoClassDefFoundError


The taskdef in b.xml looks like:

        <taskdef classname="org.apache.jasper.JspC" name="jasper2" >
            <classpath id="jspc.classpath">
                <fileset dir="${tomcat.home}/bin">
                    <include name="*.jar"/>
                <fileset dir="${tomcat.home}/server/lib">
                    <include name="*.jar"/>
                <fileset dir="${tomcat.home}/common/lib">
                    <include name="*.jar"/>


I also tried using the latest ant 1.6 beta 3 and it fails the
following error on the second invocation of b.xml:

/home/mm/oscar/build_current/a.xml:19: Following error occured while
executing this line

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message