>> Tuesday, April 20, 2010
Eclipse.org has many repositories - where does the source reside for the bundles you're interested in?
Photo credit sanja gjenero
In 3.6M7, the PDE team implemented new functionality to allow you to enable including references to the source location in the manifests of your binary bundles. To enable this in your build, you need to invoke your build with bundles from I20100414-1200 or later and add the following
to the build.properties of your builder.
During the build process, PDE build generates a file called sourceReferences.properties in same directory as your generated fetch scripts that lists all repository information for the bundles compiled from source. It looks something like this:
#Tue Apr 20 09:23:19 EDT 2010
The source references are generated from the map files. If you specify extssh connections in your map files, you may want to replace them in the sourceReferences.properties file with pserver connections in the postFetch phase. Only committers use ssh to connect to eclipse.org :-)
The resulting bundles from the build will with have a new Eclipse-SourceReferences header in their manifests. The manifest for the org.eclipse.osgi bundle from today's integration build is an example.
The source references in the manifest can be consumed by PDE when you import a binary bundle into your workspace, so you can easily find the source. When you import your bundles, you can select Import As Projects from a repository.
Select the bundle(s) to import
You'll be prompted if you want to import the version specified in the manifest or from HEAD. Since the bundles we are using are from an integration build and have the version specified, we'll use the v20100419 version.
You'll be prompted for a connection to use and then voila! Version 20100419 of org.eclipse.osgi will appear in your workspace.
This should be useful to people to find the source of the eclipse projects that they would like to contribute to or consume. It would also be interesting to see how this works with other SCMs, all of our source resides in CVS.
Thanks PDE team!
For more information see the following bugs
Support embedding repository information in released bundles
Test generating source references in the build