Generate an OSGi source bundle
------------------------------
Key: JRUBY-5492
URL: http://jira.codehaus.org/browse/JRUBY-5492
Project: JRuby
Issue Type: New Feature
Components: Java Integration
Affects Versions: JRuby 1.6RC2
Reporter: Hugues Malphettes
Priority: Minor
This might be an enhancement that applies to a niche-market only.
Eclipse OSGi development support the notion of source bundles.
It let developers link the java sources of a bundle to a runtime compiled
bundle.
Very useful for debugging.
Obviously it is only useful if you are debugging jruby running in OSGi from
Eclipse-PDE.
Here is the additional target in the build file that I am using:
<!-- Generates a jar that contains the jruby java sources.
The META-INF/MANIFEST.MF enables eclipse PDE to link the jruby bundle to
the java sources
and make the debugging of jruby in OSGi a nice and pleasant experience.
http://help.eclipse.org/ganymede/index.jsp?topic=/org.eclipse.pde.doc.user/tasks/pde_individual_source.htm
-->
<target name="dist-src-osgi-bundle" depends="jar-complete">
<mkdir dir="${dist.stage.src.dir}/osgi-src-bundle/src"/>
<copy todir="${dist.stage.src.dir}/osgi-src-bundle/src">
<fileset dir="${basedir}/src">
<include name="org/**/*"/>
<exclude name="org/jruby/runtime/Constants.java"/>
</fileset>
</copy>
<mkdir dir="${dist.stage.src.dir}/osgi-src-bundle/src_gen"/>
<copy todir="${dist.stage.src.dir}/osgi-src-bundle/src_gen">
<fileset dir="${basedir}/src_gen"/>
</copy>
<jar destfile="${dest.lib.dir}/org.jruby.jruby.source_${version.jruby}.jar"
duplicate="fail">
<fileset dir="${dist.stage.src.dir}/osgi-src-bundle/src_gen"/>
<fileset dir="${dist.stage.src.dir}/osgi-src-bundle/src"/>
<manifest>
<!-- these entries make an osgi bundle of the sources that eclipse-PDE
links to the actual bundle. useful for SDK debugging.
doc:
http://help.eclipse.org/ganymede/index.jsp?topic=/org.eclipse.pde.doc.user/tasks/pde_individual_source.htm
-->
<attribute name="Bundle-ManifestVersion" value="2"/>
<attribute name="Eclipse-SourceBundle"
value="org.jruby.jruby;version="${version.jruby}";roots:=".""/>
<attribute name="Bundle-Name" value="JRuby Java Sources"/>
<attribute name="Bundle-SymbolicName" value="org.jruby.jruby.source"/>
<attribute name="Bundle-Version" value="${version.jruby}"/>
<attribute name="Bundle-Vendor" value="jruby.org"/>
</manifest>
</jar>
</target>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email