Sunday, April 14, 2013

Consuming emf bundles from p2 with maven : b3

Some of the eclipse libraries are not so thightly bound to OSGi and lately I wanted to use EMF in a grails project. It came to me that there are no current maven artifacts available for EMF, so I had to roll my own.

Asking stackoverflow, I first tried to re-jar the bundles with tycho, but that gave me all the OSGI-deps in one jar, what wasn't what I was looking for. After reding through some discussions around maven and p2 in the eclipse bugzilla, I noticed that b3 has the capability to mirror a p2 repository in a maven compliant layout.

As I wanted to use the xsd to ecore converter I created a aggregation for the xsd sdk
notice the maven config at the end of the aggregator tag.

Then I uploaded it to google drive, so that I can consume the repo from heroku build. One major drawback is, that the source bundles are not maven conformant, so that attaching them automagically won't work.

1 comment:

Johannes Utzig said...

You can also do this with
This also doesn't support source bundles but I forked the plugin to enable this.
Using the fork, the plugin converts all source bundles to source classifiers that are attached to the main artifact.

With that

Using Mapstruct with Protobuf3