Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Setting execution classpath in Ant

 
Tebogo Modiselle
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
just a question on ANT, if my project is
/tmp/antexample
/tmp/antexample/build
/tmp/antexample/build/classes
/tmp/antexample/src
/tmp/antexample/build.xml then

my classpath for execution would be
<path id="/tm/antexample/build/classes">
<pathelemennt location="/tmp/antexample/build/classess">
</p>

Im trying to get there, I can clean, compile and no error as soon as i run "ant execute" i also get that error. but i downloaded some ant example on the Internet and executed it in comparison to my application but it works and mine doesn't want to.

what am i doing wrong?
 
Peter Johnson
author
Bartender
Posts: 5856
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Tebogo, welcome to Java Ranch!

First, the classpath id should be a simple identifier. So you might want to use something like this:



Second, you didn't show us the <java> task declaration, we need to see that to ensure that you reference the classpath correctly. Basically you want to add a classpathref that uses the path's id. In other words:



Third, there are a couple of typos the <path> you posted. I hope those typos are not in your actual build script.

If none of this helps, post the full build.xml file and the full output when you run the build.

P.S. I split your post into a separate topic because it is usually not a good idea to ask new questions on threads that are very old.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic