Skip to content
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

Enable OSGi and allow calling drawImage with null op like JDK does #1

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

makusuko
Copy link

No description provided.

@jfree
Copy link
Owner

jfree commented Dec 7, 2018

I've separately committed a fix for the ImageOp issue. I want to understand the impact of the OSGi change, so I'll need to research that a bit more.

@makusuko
Copy link
Author

Thanks!

The change related to OSGi only adds a few new items to the META-INF/MANIFEST.MF file of the resulting jar. Otherwise the resulting jar is identical and everything works the same in any Maven or Gradle projects using the dependency. Only difference is, that OSGi aware applications can now use the jar as OSGi module (i.e. the bundle plugin exports the Java packages implemented in the library).

@makusuko makusuko closed this Dec 10, 2018
@makusuko makusuko reopened this Dec 10, 2018
@jfree
Copy link
Owner

jfree commented Dec 12, 2018

OK, thanks. My next question is how to combine your change along with another request to add an automatic module name to the manifest file in the jar? I'm not so knowledgeable in Maven, but your change uses a different plugin to create the jar file so I'm not sure how to go about this.

Is there an alternative way to provide the osgi info in the manifest file?

@makusuko
Copy link
Author

The bundle packaging together with the bundle plugin automatically creates all the necessary OSGi headers based on the generated classfiles. The other way is to manually create the OSGi headers and to add them to the manifest in the jar plugin. Then of course, they must be kept up-to-date manually.

Changing the project packaging from jar to bundle and adding the bundle plugin won't break or change anything, except it adds the OSGi headers - otherwise the project keeps working the same and can be used as a traditional jar dependency.

The bundle plugin comes from Apache Felix project, is standard stuff on Maven Central repository and it is being used by a lot of projects - especially those coming from the Apache project: for example see https://mvnrepository.com/tags/bundle

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants