• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Ant build in Tomcat

 
Ranch Hand
Posts: 267
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
HiAll,
I installed tomcat 3.2.1 & now I am trying to configure how to build my source using ANT.. I followed the instructions in tomcats source organization doc. Accordingly I have a build.bat in my source root directory but when I run that I get an error..The build.bat file has the following in it:
@echo on
rem build.bat -- Build Script for the "Hello, World" Application
rem $Id: source.html,v 1.2.4.2 2000/11/27 22:45:49 craigmcc Exp $
set _CP=%CP%
rem Identify the custom class path components we need
set CP=%TOMCAT_HOME%\lib\ant.jar;%TOMCAT_HOME%\lib\servlet.jar
set CP=%TOMCAT_HOME%\lib\jaxp.jar;%TOMCAT_HOME%\lib\parser.jar
set CP=%CP%;%JAVA_HOME%\lib\tools.jar
rem Execute ANT to perform the requird build target
java -classpath %CP%;%CLASSPATH% org.apache.tools.ant.Main -Dtomcat.home=%TOMCAT_HOME% %1 %2 %3 %4 %5 %6 %7 %8 %9
set CP=%_CP%
set _CP=
//end of file
[Note: My TOMCAT_HOME & JAVA_HOME variables are set]
The error I am getting is as follows:

c:\jakarta-tomcat-3.2.1\MyProject>java -classpath \lib\jaxp.jar;\lib\parser.jar;C:\Java\jdk1.3\lib\tools.jar;c:\j2sdkee
1.2.1\lib\j2ee.jar;c:\multipart\lib\cos.jar org.apache.tools.ant.Main -Dtomcat.home=
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/tools/ant/Main
I would appreciate any help in this matter.
Thanks,
Roopa
 
Roopa Bagur
Ranch Hand
Posts: 267
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ok guys I finally fixed it.

Originally posted by Roopa Bagur:
HiAll,
I installed tomcat 3.2.1 & now I am trying to configure how to build my source using ANT.. I followed the instructions in tomcats source organization doc. Accordingly I have a build.bat in my source root directory but when I run that I get an error..The build.bat file has the following in it:
@echo on
rem build.bat -- Build Script for the "Hello, World" Application
rem $Id: source.html,v 1.2.4.2 2000/11/27 22:45:49 craigmcc Exp $
set _CP=%CP%
rem Identify the custom class path components we need
set CP=%TOMCAT_HOME%\lib\ant.jar;%TOMCAT_HOME%\lib\servlet.jar
set CP=%TOMCAT_HOME%\lib\jaxp.jar;%TOMCAT_HOME%\lib\parser.jar
set CP=%CP%;%JAVA_HOME%\lib\tools.jar
rem Execute ANT to perform the requird build target
java -classpath %CP%;%CLASSPATH% org.apache.tools.ant.Main -Dtomcat.home=%TOMCAT_HOME% %1 %2 %3 %4 %5 %6 %7 %8 %9
set CP=%_CP%
set _CP=
//end of file
[Note: My TOMCAT_HOME & JAVA_HOME variables are set]
The error I am getting is as follows:

c:\jakarta-tomcat-3.2.1\MyProject>java -classpath \lib\jaxp.jar;\lib\parser.jar;C:\Java\jdk1.3\lib\tools.jar;c:\j2sdkee
1.2.1\lib\j2ee.jar;c:\multipart\lib\cos.jar org.apache.tools.ant.Main -Dtomcat.home=
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/tools/ant/Main
I would appreciate any help in this matter.
Thanks,
Roopa


 
reply
    Bookmark Topic Watch Topic
  • New Topic