...
>> i'm a newbie to Ant. i'm trying to create jar file using ant.
...
>You have 2 options: you can either form a single jar ..
...
>The other option is to specify class path information in your jar's
>manifest file. ...
There is at least one more option. If the app. is to be
launched by web start, the 'option 2' listed above will
not work. Instead, the deployer could reference the
extra jars from the JNLP file.
Note to the OP. The word "I" and abbreviation "I'm"
should always start with a Capital Letter.

Signature
Andrew Thompson
http://www.athompson.info/andrew/
Martin Gregorie - 02 Nov 2007 18:29 GMT
> ..
>>> i'm a newbie to Ant. i'm trying to create jar file using ant.
[quoted text clipped - 3 lines]
>> The other option is to specify class path information in your jar's
>> manifest file. ...
Note that:
"The Class-Path header points to classes or JAR files on the local
network, not JAR files within the JAR file or classes accessible over
internet protocols. To load classes in JAR files within a JAR file into
the class path, you must write custom code to load those classes. For
example, if MyJar.jar contains another JAR file called MyUtils.jar, you
cannot use the Class-Path header in MyJar.jar's manifest to load classes
in MyUtils.jar into the class path."
- from "Adding Classes to the JAR File's Classpath" in the JAR Files
trail in the Java Tutorial.
IOW if you want to leave the packaged jar files on your jar file you'll
have to write a custom class loader, though that may not be very
difficult. However, the simple approach would be to put the other jar
files in the same directory as your jar file and zip the lot for
distribution. Your manifest then merely lists the other jar files and
installation consists of unzipping the archive some place and adjusting
the destination host's class path as needed.

Signature
martin@ | Martin Gregorie
gregorie. | Essex, UK
org |