Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.
Difference between revisions of "Orbit Source Bundles"
Line 55: | Line 55: | ||
customBuildCallbacks.inheritall=true | customBuildCallbacks.inheritall=true | ||
</pre> | </pre> | ||
+ | |||
+ | |||
+ | ===Utility to generate source bundles=== | ||
+ | Given an orbit bundle loaded in your workspace, the attached script will generate a corresponding source bundle following the shape described above. | ||
+ | To use the utility: | ||
+ | * import the archive in your workspace | ||
+ | * edit the build.xml to refer to the location of the bundle for which source is being generated | ||
+ | * execute the script | ||
+ | |||
+ | http://wiki.eclipse.org/index.php/Image:SourceGen.zip | ||
[[Category : Orbit]] | [[Category : Orbit]] |
Revision as of 09:58, 15 May 2007
Created from bug 184026.
Contents
What you need to do
If you have bundles in Orbit and you would like to have source bundles automatically generated for you, this is what you have to do:
- put your bundles in the structure below
- add a map file entry for your source bundle
- add your bundle (NOT your source bundle) to the feature
Bundle structure
{plugin_root} META-INF/MANIFEST.MF plugin.xml plugin.properties build.properties {class_files} ... source-bundle/ META-INF/MANIFEST.MF plugin.xml build.properties customCallbacks.xml ... src/{plugin_id}_{version}/src.zip
customCallbacks.xml
<?xml version="1.0" encoding="UTF-8"?> <project name="customCallbacks" default="post.gather.bin.parts" basedir="."> <target name="post.gather.bin.parts"> <echo message="${target.folder}" /> <echo message="${build.result.folder}" /> <pathconvert property="binaryBundleId"> <path> <fileset dir="${target.folder}/src" includes="**" /> </path> <regexpmapper from=".*\\(.*)_(.*)\\.*" to="\1" /> </pathconvert> <pathconvert property="sourceFolderVersion"> <path> <fileset dir="${target.folder}/src" includes="**" /> </path> <regexpmapper from=".*\\(.*_.*)\\.*" to="\1" /> </pathconvert> <move todir="${target.folder}/src/${binaryBundleId}_${bundleVersion}"> <fileset dir="${target.folder}/src/${sourceFolderVersion}" includes="**" /> </move> </target> </project>
build.properties
customBuildCallbacks=customCallbacks.xml customBuildCallbacks.inheritall=true
Utility to generate source bundles
Given an orbit bundle loaded in your workspace, the attached script will generate a corresponding source bundle following the shape described above. To use the utility:
- import the archive in your workspace
- edit the build.xml to refer to the location of the bundle for which source is being generated
- execute the script