• 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

Problems using Ant 1.5.4

 
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Guys

I have been using Ant 1.6 happily for months, but a tool I want to use (Scarab) needs Ant 1.5.x in order to install.

I have installed Ant 1.5.4 - set the ant_home directory and set it up in the path - which seems to be the only thing I need to change (java_home and so on are already done).

I try to use ant from the directory with the build.xml in it - and get the following error:

Usage: java [-options] class [args...]
(to execute a class)
or java [-options] -jar jarfile [args...]
(to execute a jar file)

where options include:
-client to select the "client" VM
-server to select the "server" VM
.... yada yada yada ...

So it is clear that java isn't executing the ant jar properly. Here is the output from the ant.bat which causes it to fall over

E:\projects\scarab-1.0-b19\build>"E:\j2sdk1.4.2_03\bin\java.exe" -classpath "E:
\j2sdk1.4.2_03\lib\tools.jar;E:\java libraries\apache-ant-1.5.4\\lib\xml-apis.ja
r;E:\java libraries\apache-ant-1.5.4\\lib\xercesImpl.jar;E:\java libraries\apach
e-ant-1.5.4\\lib\optional.jar;E:\java libraries\apache-ant-1.5.4\\lib\ant.jar;"
"-Dant.home=E:\java libraries\apache-ant-1.5.4\" org.apache.tools.ant.Main

I'm sure there is a sensible solution to this. Is there some conflict between java 1.4 and ant 1.5?

The problem happens even where it was working before I changed the installation.

Other details: winxp prof, java 1.4.2, ant 1.5.4? that would be my guess. But what is it? and, more importantly, what should I do about it?

Any thoughts anyone?

Alister
 
Alister Pate
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
well slap my **** and call me Mary.

ANT_HOME should look like this: E:\java libraries\apache-ant-1.5.4
notlike this: E:\java libraries\apache-ant-1.5.4\

Notice the final "\". You wouldn't think I'd been doing this stuff for night on eight years would you?

D'oh!

<I just wish I could delete the previous post, save myself embarassment. Oh well. Live and learn. >


Alister
 
reply
    Bookmark Topic Watch Topic
  • New Topic