-
-
Notifications
You must be signed in to change notification settings - Fork 300
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for building multi-release jars (automatic!) #5359
Conversation
I have adjusted the example here to reflect the changes, the |
This adds methods to the Jar class to read versioned content of a multi-release jar for the following cases: - get a resource or a map of resources for a given release version - get a merged manifest according to the OSGi specification - get module name/version for a given given release version - list all contained release alternative versions Beside this a unit-test is added to cover these new functions. Signed-off-by: Christoph Läubrich <laeubi@laeubi-soft.de>
6c432c0
to
e63ee71
Compare
I think the direction here is good. We probably need some more multi-release bundle generation tests before it can be merged though. |
Can you suggest a test-case that might be adapted for this purpose?
According to my tests (see attached generated bundle) it simply "works", e.g. I see |
This changes enable BND user to set Multi-Release: true in a BND file and then creates a bundle that conforms to the OSGi Multi-release JAR specification Signed-off-by: Christoph Läubrich <laeubi@laeubi-soft.de>
I have added now a test here: bnd/biz.aQute.bndlib.tests/test/aQute/bnd/osgi/AnalyzerTest.java Lines 24 to 53 in 51a4947
|
I will take over this PR |
This is based on:
so to see the actual changes from this PR simply select the last commit on the review tab.
an allows to specify
Multi-Release: true
in a BND file to instruct BND building an OSGi Multi-Release Bundle based on the detected versions.
@timothyjward this also includes fixing general processing of BND in cases where multi-release is off, and methods for
Jar
to put versioned resources / supplemental manifests. If you think it helps, both aspects could be split into separate PRs as well.This will fix #5346