-
Notifications
You must be signed in to change notification settings - Fork 602
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
Please publish the source jar with OSGI manifest headers, too #242
Comments
@15knots Could you check whether a |
Thanks for the quick response, first. Sorry, neither my local build nor the 0.16.0 version on maven central has the proper manifest headers.
In the above,
For builds with maven, I simply use the <archive>
<manifestEntries>
<Bundle-ManifestVersion>2</Bundle-ManifestVersion>
<Bundle-Name>${project.name} Source</Bundle-Name>
<Bundle-SymbolicName>${project.groupId}.${project.artifactId}.source</Bundle-SymbolicName>
<Bundle-Version>${parsedVersion.osgiVersion}</Bundle-Version>
<Eclipse-SourceBundle>${project.groupId}.${project.artifactId};version="${parsedVersion.osgiVersion}";roots:="."</Eclipse-SourceBundle>
<Bundle-Vendor>${project.organization.name}</Bundle-Vendor>
</manifestEntries>
</archive> |
Thanks. I'll fix this for the next release! Op di 12 apr. 2016 22:07 schreef 15knots [email protected]:
|
Please PM me an URL for beta-testing that prior to releasing it.
|
Just committed 317bbfa on branch https://github.com/hierynomus/sshj/tree/issue-242 Can you build that branch and see whether the manifest looks better now? |
Wow,
It still has the Im-/Export headers. With the patch, it looks better, |
Thanks, will have a look! 2016-04-13 22:43 GMT+02:00 15knots [email protected]:
|
Got it! task sourcesJar(type: Jar) {
classifier = 'sources'
from sourceSets.main.allSource
manifest { // manifest is NOT of type OsgiManifest
attributes(
"Bundle-ManifestVersion": "2",
// copy values from binary jar manifest to be consistent...
"Eclipse-SourceBundle": project.jar.manifest.getSymbolicName()
+ ";version=\"" + project.jar.manifest.getVersion() + "\";roots:=\".\"",
"Bundle-SymbolicName": project.jar.manifest.getSymbolicName() + ".source",
"Bundle-Version": project.jar.manifest.getVersion()
"Bundle-Name": project.jar.manifest.getName() + " Source",
)
}
} Please carefully review, I'm a gradle newbie. Gives
Eclipse target definition looks good, target content the same and the eclipse editor is showing the source. |
Fixed it, thanks for looking at it. Do you need an 0.16.1 release with the fixed manifests? |
Yes, please release 0.16.1 Plus you could mention in the README, that sshj now has proper manifest headers for OSGI and is ready for incorporation into a p2 repo. That way, it can be used to build Eclipse bundles. |
The implementation jar of sshj on maven central already has proper OSGI manifest headers, which makes it easy to put that jar into a p2 repository to use sshj as an Eclipse bundle.
But the source jar does not have the appropriate OSGI manifest headers. If one puts the source jar into a p2 repository for use in a target platform, the Eclipse IDE will not find and show the Java sources when debugging.
I am willing to help with this, but I do not know gradle (only maven).
The text was updated successfully, but these errors were encountered: