What about using Ant to set your classpath! If your are using ant
reguraly you can easily add a target to Ant , that will add the
specified libs in your classpath. After that you can the rest of the
tasks! 

Hope it helped!

-----Original Message-----
From: Mitch Gitman [mailto:[EMAIL PROTECTED]] 
Sent: Sunday, February 09, 2003 6:33 AM
To: [EMAIL PROTECTED]
Subject: RE: Axis TaskDef


To run the Axis-specific Ant task axis-java2wsdl, I too had to set the 
classpath via the command line to include axis.jar, axis-ant.jar, and
the 
rest of the Axis archives. I'm wondering if anyone has come up with a 
cleaner way to specify the classpath for axis-java2wsdl.

At 12:40 2003.01.23 -0600, Cory Wilkerson wrote:
>James,
>
>Thanks -- I managed to get it to work by specifying both the axis.jar 
>and
>the axis-ant.jar on the command line before invoking ant -- however, it

>still won't work if I just create a standard classpath element as a
child 
>of taskdef in the script.
>
>Strange, sure I'm just missing something,
>Cory
>...
>-----------------------------------------------------
><?xml version="1.0" encoding="UTF-8"?>
><project name="axis" basedir="." default="init">
>     <taskdef resource="axis-tasks.properties"/>
></project>
>
>BUILD FAILED
>build.xml:3: taskdef class 
>org.apache.axis.tools.ant.wsdl.Wsdl2javaAntTask
>cannot be found
>
>If I have ant dump it's classpath prior to execution...the axis-ant.jar

>is clearly in the task path:
>
>LOCAL 
>CLASSPATH=c:\devtools\jakarta-ant-1.5.1\lib\xml-apis.jar;c:\devtools\ja
>kar
>ta-ant-1.5.1\lib\xercesImpl.jar;c:\devtools\jakarta-ant-1.5.1\lib\optio
nal.j
>ar;c
>:\devtools\jakarta-ant-1.5.1\lib\ant.jar;c:\devtools\axis-1_1beta\lib\a
xis-a
>nt.jar
>-----------------------------------------------------
>
>Perhaps I'm using the taskdef wrong??  If I specify the classpath in 
>the task and remove it
>from ant's classpath I see the same issue.   It's finding the
properties
>file...just not finding
>the associated classes.
>
>-----------------------------------------------------
><?xml version="1.0" encoding="UTF-8"?>
><project name="axis" basedir="." default="init">
>     <taskdef resource="axis-tasks.properties" 
>classpath="C:/DEVTOOLS/axis-1_1beta/lib/axis-ant.jar"/>
></project>
>
>BUILD FAILED
>build.xml:3: taskdef class 
>org.apache.axis.tools.ant.wsdl.Wsdl2javaAntTask
>cannot be found
>
>LOCAL 
>CLASSPATH=c:\devtools\jakarta-ant-1.5.1\lib\xml-apis.jar;c:\devtools\ja
>kar
>ta-ant-1.5.1\lib\xercesImpl.jar;c:\devtools\jakarta-ant-1.5.1\lib\optio
nal.j
>ar;c
>:\devtools\jakarta-ant-1.5.1\lib\ant.jar;
>-----------------------------------------------------
>
>Cory


Reply via email to