This week's book giveaway is in the Cloud/Virtualization forum.
We're giving away four copies of Building Blockchain Apps and have Michael Yuan on-line!
See this thread for details.
Win a copy of Building Blockchain Apps this week in the Cloud/Virtualization forum!
  • 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Liutauras Vilda
  • Knute Snortum
  • Bear Bibeault
Sheriffs:
  • Devaka Cooray
  • Jeanne Boyarsky
  • Junilu Lacar
Saloon Keepers:
  • Ron McLeod
  • Stephan van Hulst
  • Tim Moores
  • Carey Brown
  • salvin francis
Bartenders:
  • Tim Holloway
  • Piet Souris
  • Frits Walraven

setting ANT class path

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi iam running an webservice application, i created an simple application by writing Java class then i created build .xml...

<project name="Calculator Service" default="ear">
<target name="ear">
<servicegen destEar="Calc.ear" contextURI="Calc">
<service
javaClassComponents="Calc.Calculator"
targetNamespace="www.Arun.com"
serviceName="CalculatorService"
serviceURI="/CalculatorService"
generateTypes="True"
expandMethods="True"
style="rpc">
</service>
</servicegen>
</target>
</project>
when i typed ant on command prompt some errors C:\Arun\Arun\java2ws> ommand,

C:\Arun\Arun\java2ws>
C:\Arun\Arun\java2ws>Ant could not find the task or a class this task relies upo
n.
Buildfile: build.xml

BUILD FAILED
Target `could' does not exist in this project.

Total time: 0 seconds
C:\Arun\Arun\java2ws>
C:\Arun\Arun\java2ws>This is common and has a number of causes; the usual
'This' is not recognized as an internal or external command,
operable program or batch file.

C:\Arun\Arun\java2ws>solutions are to read the manual pages then download and
'solutions' is not recognized as an internal or external command,
operable program or batch file.

C:\Arun\Arun\java2ws>install needed JAR files, or fix the build file:
'install' is not recognized as an internal or external command,
operable program or batch file.

C:\Arun\Arun\java2ws> - You have misspelt 'servicegen'.
'-' is not recognized as an internal or external command,
operable program or batch file.

C:\Arun\Arun\java2ws> Fix: check your spelling.
'Fix:' is not recognized as an internal or external command,
operable program or batch file.

C:\Arun\Arun\java2ws> - The task needs an external JAR file to execute
'-' is not recognized as an internal or external command,
operable program or batch file.

C:\Arun\Arun\java2ws> and this is not found at the right place in the classp
ath.
'and' is not recognized as an internal or external command,
operable program or batch file.

C:\Arun\Arun\java2ws> Fix: check the documentation for dependencies.
'Fix:' is not recognized as an internal or external command,
operable program or batch file.

C:\Arun\Arun\java2ws> Fix: declare the task.
'Fix:' is not recognized as an internal or external command,
operable program or batch file.

C:\Arun\Arun\java2ws> - The task is an Ant optional task and the JAR file and/or
libraries
'-' is not recognized as an internal or external command,
operable program or batch file.

C:\Arun\Arun\java2ws> implementing the functionality were not found at the t
ime you
'implementing' is not recognized as an internal or external command,
operable program or batch file.

C:\Arun\Arun\java2ws> yourself built your installation of Ant from the Ant s
ources.
'yourself' is not recognized as an internal or external command,
operable program or batch file.

C:\Arun\Arun\java2ws> Fix: Look in the ANT_HOME/lib for the 'ant-' JAR corresp
onding to the
'Fix:' is not recognized as an internal or external command,
operable program or batch file.

C:\Arun\Arun\java2ws> task and make sure it contains more than merely a META
-INF/MANIFEST.MF.
'task' is not recognized as an internal or external command,
operable program or batch file.

C:\Arun\Arun\java2ws> If all it contains is the manifest, then rebuild Ant w
ith the needed
it was unexpected at this time.

C:\Arun\Arun\java2ws> libraries present in ${ant.home}/lib/optional/ , or al
ternatively,
'libraries' is not recognized as an internal or external command,
operable program or batch file.

C:\Arun\Arun\java2ws> download a pre-built release version from apache.org
'download' is not recognized as an internal or external command,
operable program or batch file.

C:\Arun\Arun\java2ws> - The build file was written for a later version of Ant
'-' is not recognized as an internal or external command,
operable program or batch file.

C:\Arun\Arun\java2ws> Fix: upgrade to at least the latest release version of A
nt
'Fix:' is not recognized as an internal or external command,
operable program or batch file.

C:\Arun\Arun\java2ws> - The task is not an Ant core or optional task
'-' is not recognized as an internal or external command,
operable program or batch file.


but i instaled on the paths in my classpath.

can u help me in this regard

Thanks
 
Sheriff
Posts: 11343
Mac Safari Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Moving to the forum for Ant, Maven, and other Build Tools.
 
author & internet detective
Posts: 39890
798
Eclipse IDE VI Editor Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Arun,
It's not enough to add the jars to your system classpath. You have to either put them in the ANT_HOME/lib directory or add them to the classpath (command line) when you run Ant.
 
I like tacos! And this tiny ad:
Java file APIs (DOC, XLS, PDF, and many more)
https://products.aspose.com/total/java
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!