• 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
  • Tim Cooke
  • paul wheaton
  • Liutauras Vilda
  • Ron McLeod
Sheriffs:
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Saloon Keepers:
  • Scott Selikoff
  • Tim Holloway
  • Piet Souris
  • Mikalai Zaikin
  • Frits Walraven
Bartenders:
  • Stephan van Hulst
  • Carey Brown

Ant classpath problem

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I am trying to write a jar task it works, however, when I run my program, I get an exclamation mark at the end of the jar file path and this messes up some of my path references inside my code.
Here is a copy of my target, if anyone knows what's wrong?
<target name="dist"
depends="compile"
description="Generate the Distribution.">
<mkdir dir="${dest.dir}/" />
<mkdir dir="${dest.dir}/lib" />
<!--jar jarfile="${dest.dir}/lib/${jarName}" basedir="${build.dir}" compress="false" update="no"-->
<jar jarfile="${dest.dir}/lib/${jarName}" compress="false" update="no">
<!-- include all the .class files -->
<fileset dir="${build.dir}"/>
<!--include the res and config files: i.e. defaultConfig, images-->
<fileset dir="${res.dir}"/>

<!-- our default properties and build information -->
<manifest>
<attribute name="Main-Class" value="AutomatedTestTool" />
<attribute name="Class-Path" value="comm.jar jaxen-core.jar jaxen-jdom.jar
jdom.jar saxpath.jar xalan.jar xerces.jar xercesImpl.jar xmlParserAPIs.jar xml-apis.jar" />
<attribute name="Implementation-Vendor" value="Ross Video Ltd." />
</manifest>
</jar>
<copy todir="${dest.dir}/lib" overwrite="yes">
<fileset dir="${lib.dir}">
<include name="comm.jar" />
<include name="jaxen-core.jar" />
<include name="jaxen-jdom.jar" />
<include name="jdom.jar" />
<include name="saxpath.jar" />
<include name="xalan.jar" />
<include name="xercesImpl.jar" />
<include name="xmlParserAPIs.jar" />
<include name="xml-apis.jar" />
</fileset>
</copy>
<!--copy file="${configName}" todir="${dest.dir}" overwrite="yes">
</copy-->
</target>
when I run the jar my path is the jar like this: /sdfs.jar!
 
author
Posts: 11962
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
This belongs to the Ant forum so I'll move it there.
 
Lasse Koskela
author
Posts: 11962
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
This snippet doesn't show where ${jarName} gets its value from?
 
Politics n. Poly "many" + ticks "blood sucking insects". Tiny ad:
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic