[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [equinox-dev] bundle builds using Maven
- From: "Alex Blewitt" <alex.blewitt@xxxxxxxxx>
- Date: Thu, 17 May 2007 08:35:14 +0100
- Delivered-to: firstname.lastname@example.org
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=ePweAk2YOD2SrfQZqeoZohukx7O9O4iyj42eI8Zb/mqwhOccArJJQIw8UoUvovBth9AzWkLEP8grhznE99HzzfPRTMGgQKjd7G3wvJD462ZlMao2B9E2vAArHujVLu1ONXtDo3E/tt9t429ja1QLAE47diXc10ELTSkE53TC2z4=
On 17/05/07, Stuart McCulloch <stuart.mcculloch@xxxxxxxxxx> wrote:
On 17/05/07, Aaron Siri <Aaron.Siri@xxxxxxx> wrote:
> Thanks for the replies. I realized what I was doing wrong. You must call
> "mvn install" for it to properly build. "mvn compile" (which I was trying to
> use) doesn't place the dependencies in the local repo for the dependant
> modules to build from.
yep, I've seen a lot of people hit the same problem when using maven to
build OSGi bundles, so I try to get people used to 'mvn install' in tutorials.
Actually, it's pretty easy to set up Maven to build OSGi bundles -- in
fact, about as easy as it is for other Java projects. What doesn't
work so well is trying to use Eclipse PDE to edit/test those bundles
in a Maven layout. Whilst Maven looks as the Manifest.mf as something
that's generated, Eclipse PDE treats it as a source file to be edited.
So you end up duplicating dependency references.
It's notable that using Maven to build Java projects suffers none of
these problems, since in Java projects everything's taken from the set
of output directories, so it's trivial to set up a source folder for
mapping the resources into the output.
If one wanted to break backward compatibility for existing PDE
layouts, it would be possible to fix the eclipse -dev hook to search
for resources via getEntry() relatively to the build output folder
instead of relative to the project folder. But since that's
effectively a backwardly-compatible break, it's not going to happen.