ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Steve Loughran <ste...@apache.org>
Subject Re: Build jar files that contain other jar files
Date Wed, 01 Nov 2006 11:49:54 GMT
Keith Hatton wrote:
> You can include other jars in the Class-Path entry of the manifest file
> of your jar, then just distribute all jars in the same folder (assuming
> you're allowed to distribute them).
> 

the advantage of this route is:

  1. you dont secretly include other jars in your app. I have a special 
hand-made version of jython.jar that strips out the apache regexp 
libraries for that reason.

2. you can depend on signed jars and the signature is not affected.

Against, that you are very brittle against the JARs being exactly where 
you expected them, and named exactly what you want.

Java app dependency logic sucks. I have just been discussing OSGi with 
someone as an alternative (see apache felix), but even that has limitations.

Ant1.7 probably lets you import JARs into JARs by way of resources, even 
though I normally dont approve. If you are doing something in-house or 
java-web-start, go for it, but for things that are widely redistributed, 
its just a source of support calls.

-steve

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


Mime
View raw message