Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [tycho-dev] [tycho-user] <optionalDependencies> configuration parameter

Igor Fedorenko wrote:
> On 12-01-09 8:19 AM, Oberlies, Tobias wrote:
> >
> > Igor Fedorenko wrote:
> >> So, do we agree that the test runtime should always ignore optional
> >> dependencies defined in test bundle manifest and the user will need to
> >> use explicit pom.xml configuration to control what dependencies are
> used
> >> by the tests?
> >
> > I would say yes for normal, optional dependencies. I'm unsure what
> > should happen if the optional dependencies are made greedy through
> > x-installation:=greedy.
> >
> Does P2 already take care of x-installation?

Yes, it does. When x-installation is set, p2 generates an optional-greedy dependency that is satisfied when possible.

> >> Please note that this only affects dependencies of the test bundle
> >> itself, all indirect optional dependencies are already ignored.
> >>
> >>
> >
> > Is this the case now, or only once this bug is fixed?
> >
> This is already the case now, as far as I know.
> The version of P2 used by Tycho 0.13 and newer interprets OSGi
> resolution:=optional as P2 optional/nongreedy requirements... and I am
> pretty sure you made this change ;-)

Oh, okay, now I see what you mean. Yes this works for dependencies to outside the reactor, but for things within the reactor, the optionalDependencies compiler parameter determines how optional dependencies are treated. This is because the test runtime is created from the dependency-only metadata, and not from the final metadata. We should be able to change this once we have the full target platform object in place (bug 364134 [1]), if we want to.



Back to the top