[
https://issues.apache.org/jira/browse/COMPRESS-456?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16517221#comment-16517221
]
Stefan Bodewig commented on COMPRESS-456:
-----------------------------------------
Hmm, I'm more or less clueless when it comes to OSGi (and prefer to stay that
way ;)). In Compress' case the {{javax.crypto}} dependencies are in fact
optional they have just never been specified - you only need them when you want
to use decryption of 7z right now. But you are correct, it is probably better
to be explicit with optional dependencies.
Commit 8ed5daaa probably is the cleaner solution.
Thanks, Oliver.
> Missing OSGI Import-Package
> ---------------------------
>
> Key: COMPRESS-456
> URL: https://issues.apache.org/jira/browse/COMPRESS-456
> Project: Commons Compress
> Issue Type: Bug
> Components: Build
> Affects Versions: 1.17
> Reporter: Jérémie Brébec
> Priority: Major
> Fix For: 1.18
>
>
> The configuration of the maven-bundle-plugin overrides the <Import-Package>
> directive : "*" is not present anymore, and severals packages do not resolve
> correctly.
> For example, "javax.crypto", which is used by 7z encryption, is not resolved
> and using this feature fails with a ClassNotFoundException on
> javax.crypto.SecretKey.
> ahma I think that the correct Import-Package directive should be :
> {code:java}
> <Import-Package>*;resolution:=optional</Import-Package>{code}
> this directive will import everything commons-compress depends on, but with
> an optional resolution (and so every dependencies will be optionals)
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)