ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dominique Devienne" <ddevie...@gmail.com>
Subject Re: Specifying Jar files to execute program
Date Tue, 18 Jul 2006 16:15:05 GMT
<classpath> is ignored when using 'jar' attribute, as per Java's own
document in the JDK. Ant's documentation has been updated to more
strongly indicate that.

Either use an in-Manifest Class-Path: attribute, or use 'classname'
instead of 'jar'. --DD

On 7/18/06, Bala Paranj <bparanj@yahoo.com> wrote:
> I have the following target in my ant script:
>
> <target name="execute" depends="compile" description="run the program">
>
>  <java jar="${dist}/myClient.jar" fork="true" failonerror="true">
>        <classpath>
>          <pathelement location="${dist}/abc.jar"/>
>          <pathelement location="${dist}/xyz.zip"/>
>        </classpath>
>        <sysproperty key="javax.net.ssl.keyStore" value="client.keystore" />
>        <sysproperty key="javax.net.ssl.keyStorePassword" value="lakjflkdj" />
>        <sysproperty key="javax.net.ssl.trustStore" value="client.truststore" />
>        <sysproperty key="javax.net.ssl.trustStorePassword" value="oiruqoieur" />
>        <arg value="localhost" />
>        <arg value="8443" />
>  </java>
>
> </target>
>
> The abc.jar and xyz.zip are in the same directory (dist) and so is the myClient.jar file
that I
> want to run. But I get the java.lang.NoClassDefFoundError: name of class in abc.jar as
the error
> message.
>
> The dist folder and the ant script is within the myProject folder. How can I fix this?
TIA.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message