• Post Reply Bookmark Topic Watch Topic
  • New Topic

Setting Up Ant  RSS feed

 
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am trying to install and set up Ant 1.6.2 so I can properly set up Tomcat 5.0.19. I am working on Windows 2000.

I downloaded ant from apache and expanded it. I set the ANT_HOME environment variable and my PATH variable to the ant home and ant bin directories. However, when I run "ant -help" from the command line I receive the error:

Exception in thread "main" java.lang.NoClassDefFoundError: /;c:\j2sdk1/4/2_0\lib;c:\Blazix\Blazix/jar -help

The string "/;c:\j2sdk1/4/2_0\lib;c:\Blazix\Blazix/jar" looks like it comes from the PATH variable. The PATH includes "C:\ant\apache-ant-1.6.2\bin" and it seems to be finding the ant.bat file and trying to execute it.

Can anyone help me figure out what I'm missing?

Thank you.
 
Ranch Hand
Posts: 995
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Firstly: the classpath seems to me to be broken: to many \ and / in the same string (and not even escaped).
Try echoing/posting the values of PATH, CLASSPATH.

./pope
 
Brent Smith
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
On closer inspection of the CLASSPATH variable I found a space:

CLASSPATH=C:\j2sdk1.4.2_04\lib\vioc_lib; .;c:\j2sdk1.4.2_04\lib;c:\Blazix\Blazix.jar

After removing the space the "ant -help" command works as expected. Thanks for pointing me in the right direction.

Brent
 
author & internet detective
Marshal
Posts: 38277
627
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As this is really an Ant question, I'm moving it to our Ant forum.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!