Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [tycho-user] target platforms and Maven.

Igor,

Thanks, for your replies.

My previous post was a bit rushed and probably wasn't as clear as it could have been. I'm not necessarily after the same dependencies across the projects, rather I'm interested in getting the necessary project dependencies from the same place (ie the same target platform); and thereby guaranteeing that api1.jar needed by Tycho_proj1 is the same api1.jar used as a dependency for pojo_proj1.

Most of the POJOs are custom testing jars, while others are legacy utilities and tools that depend on the runtime classes (generated as bundles).

I can investigate moving the tests to OSGi packaging just for compilation, but I can't say I'm thrilled by the idea. I'm not certain I can change the packaging of the other tooling, though I can look into that too. I may simply have to resort to a "noop project" that uses an ant script to assemble the necessary components into a local maven repo to utilize during the POJO section of the process.

-Eric

On 07/02/2012 5:27 PM, Igor Fedorenko wrote:
No, this is not possible. By design Maven (and Tycho) treat each project
dependencies separately from all other projects, so there is no way to
express "use same dependencies as in that project" in Maven. It is also
not possible to mix Maven and Tycho dependency resolvers for the same
project.

Can't you use packaging=eclipse-plugin for all your projects? Bundle jar
is just a jar with some extra elements in jar manifest, after all. The
downside, of course, you won't be able to use these jars as dependencies
of other Maven projects.

--
Regards,
Igor

On 12-02-07 5:18 PM, Eric Gwin wrote:
yes. Basically, the orbit and other dependencies are API lib/bundles.
Many versions could be available, and certainly Maven could resolve a
different version than the P2 resolver. Whichever version is used to
build the bundles in Tycho, I want to use the same version to build the
jars.

-Eric

On 07/02/2012 4:01 PM, Igor Fedorenko wrote:
Not sure I follow. You have a Tycho project, i.e. an osgi bundle or a
repository, and you want to use dependencies of this bundle to build
another project. Did I get this right?

--
Regards,
Igor

On 12-02-07 3:48 PM, Eric Gwin wrote:
Hi,

This is probably more a maven question, but as you'll see below there is
a tie-in to tycho and eclipse, so I think this may actually the best
forum for the question.

I am in the midst of migrating a project's build system from Ant to
Maven. As a first step I've migrated the OSGi artifact's builds to
utilize Tycho for manifest first builds
(Dependencies retrieved using P2 repositories). The rest of the build is
still in Ant and uses build dependencies assembled locally from orbit,
or local OSGi'ified third party jars.

One of the goals of the change was to switch to a manifest-first build
style for the bundles, and another is to switch to a system that allows
development to utilize the same build within the IDE as the automated
"headless" nightly builds. We chose Maven/Tycho.

Once the full build has been migrated, I'll be building a mix of
standard java jars, OSGi bundles, eclipse features, generating a P2
site, and publishing artifacts to a maven repository and creating zip
"install" archives. I expect that a different reactor will have to be
used for the pure maven build (possibly more than one).

I'm currently experimenting with target definition files, it seems they
will allow us to build the tycho artifacts from the command-line or
within the IDE independent of IDE version. However, I've yet to find a
non-ant means of being able to build standard jars with Maven utilizing
the exact same dependencies used to create the bundles (Tycho).

That is basically my question. Is it possible to somehow save the
resulting P2 dependency resolution, and turn around and use it to build
"standard' jars with Maven (which normally utilizes a maven repo)?

Thanks.

-Eric

_______________________________________________
tycho-user mailing list
tycho-user@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
tycho-user@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/tycho-user

_______________________________________________
tycho-user mailing list
tycho-user@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
tycho-user@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/tycho-user



Back to the top