Handling of extracted nested jar files [message #604020] |
Thu, 07 January 2010 09:58 |
Eclipse User |
|
|
|
Originally posted by: Jens.Borrmann.gillardon.de
Hi,
like many others I have come to the conclusion that it can be a good
idea not to use nested jar files in an OSGi bundle. Now I have some
problems to convince Eclipse to handle this properly.
Let's say I have a library third party library somelibrary.jar with
package somepackage containing a class file SomeClass.class. I need
SomeClass in my own bundle that. I would like to something like the
following structure for my bundle:
src
main
java
mypackage
MyClass.java
classes
somepackage
SomeClass.class
META-INF
Manifest.MF
I do not want to put the packages from somelibrary.jar on the root of my
bundle since this can become quite nasty (Today I saw a jar containing a
top level package called temp...).
In build.properties I edited source..
source.. = src/main/java/,src/main/classes/
If I use the export wizard for exporting the plugin as a jar file
everything works well and somepackage can be found at the root of the
newly created jar file.
The only problem with my approach is that the manifest wizard for my
bundle does not "know" somepackage. If I try to add an Exported Package
on the Runtime tab I am only offered mypackage and not somepackage.
Editing MANIFEST.MF manually is possible. So is importing a manually
created export from another bundle.
So I suppose that I am missing a basic trick that would help the PDE
tools to help me. Any suggestions?
--- Jens
|
|
|
Powered by
FUDForum. Page generated in 0.04692 seconds