[kf-users] How to include all dependent jars in a bundle
nima.kaviani at gmail.com
Wed Apr 1 11:23:15 CEST 2009
apologies if my question is somehow out of the blue and is not directly
related to Knopflerfish, but I am really stuck with a problem that I believe
is fairly simple to resolve, however has kept me busy for the past few days.
In one of my bundles I am using an external jar library (simpack) which
itself has dependencies to a huge number of other jar files (like I think 30
or 40 other jar files). I am trying to wrap all these jar files into one
single bundle and let the classes in my bundle use the libraries offered by
simpack while resolving simpack's dependencies to other jar files.
Since I am not aware of what jar files simpack uses, I am having a hard time
including these additional jars into my bundle and exporting their classes
to resolve the dependency issues of simpack. I have tried modifying the
MANIFEST file to define the libraries in the classpath (specially those
required by simpack) and export their classes for simpack to use. However,
dependencies are too many and I need to constantly find and add a jar
library, update and start the bundle, get the next dependency exception, try
to resolve it, and loop.
I tried using bnd (http://www.aqute.biz/Code/Bnd) and DA-Launcher (
http://www.dynamicjava.org/projects/da-launcher) but neither seem to fit my
needs. I am not sure if Maven would solve my problem, but haven't tried to
play around with it.
I have noticed that wrapping of external jars has been well crafted into
most knopflerfish bundles. Could anybody please let me know how it can be
done and if there is any tool out there that can help me wrap all my
required jars without all this hassle.
I was reading somewhere that OSGi was designed as a remedy to the JAR HELL
(DLL HELL) problem, but to me it seems like the hell is still next door...
thanks a lot,
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Knopflerfish-users