ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Maximilian Rehm" <>
Subject AW: Problem Compiling Servlets with build file
Date Tue, 30 Jan 2001 13:15:33 GMT
I upgraded to Tomcat 3.2.1 and now when I try to run build.bat script I get
the following error:

Exception in thread "main" java.lang.NoClassDefFoundError:

When I try to run ant from the command prompt I get this error:

Buildfile: build.xml
Project base dir set to: C:\dev\partScavenger
BUILD CONFIG ERROR: Could not create task of type: copy because I can't find
in the list of task class definitions Could not create task of type: copy
 I can't find it in the list of task class definitions

I am using the sample build.bat file and the sample build.xml file that came
with Tomcat 3.2.1

I am not quite sure what the problem is because the build.bat file
initializes the classpath to the ant.jar file that comes with Tomcat.
Shouldn't ant find everything it needs in the jar file?

I've set up TOMCAT_HOME to point to the installation path of Tomcat-3.2.1

Thanks in advace for any help

-----Ursprungliche Nachricht-----
Von: Stefan Bodewig []
Gesendet: Montag, 29. Januar 2001 09:18
Betreff: Re: Problem Compiling Servlets with build file

Maximilian Rehm <> wrote:

> When trying to build my project with ant my servlets are not
> compiled and are not copied to WEB-INF/classes in my project
> directory.  All other files (eg support files) in my src directory
> are being copied no problem.

The build file you are using has been designed for a version of Ant
that was current in April 2000 (when Tomcat 3.1 has been released). I
have not tried to find all problems, but it obviously depends on an
old feature where a target named init would be treated
differently. This won't work with Ant 1.2.

> I've installed jdk1.3, tomcat 3.1 and ant 1.2 on Win2K Prof

As you are not getting any error messages I doubt you are really using
Ant 1.2, most probably you pick up an older version of it from your
CLASSPATH (i.e. remove the ant.jar that shipped with Tomcat
3.1). After that you'll have to modify the sample build file to
actually work with Ant 1.2.

The best option might be to upgrade to Tomcat 3.2.1 anyway. I *hope*
the sample build files have been adapted to Ant 1.2 there.


View raw message