Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [tycho-user] Need info about mirroring maven artifacts in a p2 mirror with Nexus

Hi,

I might have posted this before, but from what I read you could also use Eclipse Package Drone [1] for this.

You create a new channel, add the P2 repository aspect and OSGi aspects to extract metadata from existing OSGi bundles. It can then render a P2 repository which you can reference in your build.

Regards

Jens

[1] http://www.eclipse.org/package-drone/

On Mar 8, 2016 19:35, "David M. Karr" <davidmichaelkarr@xxxxxxxxx> wrote:
On 03/08/2016 10:16 AM, Dirk Fauth wrote:

Not quite sure what you mean. But you can add maven dependencies to your Tycho build using pomDependecies=consider. But yes they need to be osgi bundles.

I wrote about that some time ago. Maybe that helps.

http://blog.vogella.com/2013/01/03/tycho-advanced/


Ah, right.  That is likely why this wasn't working before (or at least one of the reasons).

Am 08.03.2016 18:54 schrieb "David M. Karr" <davidmichaelkarr@gmail.com>:
A while ago, I asked questions in here (and other channels) about my Eclipse plugin build, using Tycho, which was "hard-storing" some maven artifacts in the project instead of specifying them "declaratively".  I tried for quite a while to figure out how to specify them as Maven dependencies, but I never got it to work.

I started to understand that the only way to get this to work was to be able to access those artifacts in a p2 repository, so I can specify those dependencies in my target platform.  The administrator of the Nexus server that I use has been working on this, but he's telling me that the artifacts mirrored in this repository have to be OSGi bundles.  A "plain" Maven artifact jar won't work.

I'm now understanding that it's straightforward to "augment" an existing Maven artifact with the appropriate META-INF/MANIFEST.MF file to have it be recognized and properly used as an OSGi bundle.  This can be done at build time with the "maven-bundle-plugin", but Nexus also has the ability (I don't know the details yet) to semi-automatically add manifest info to artifacts so they can be used in a p2 repo.

However, I'm also hearing that even if the artifact is a valid OSGi bundle, it won't properly work in a p2 repo unless it can somehow see "features".  What do I have to do to plain Maven artifact jars to make them usable in an Eclipse plugin build as repository targets in a target platform specification?

_______________________________________________
tycho-user mailing list
tycho-user@eclipse.org
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/tycho-user


_______________________________________________
tycho-user mailing list
tycho-user@eclipse.org
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/tycho-user


Back to the top