You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Jason Nerothin <ja...@gmail.com> on 2007/10/16 22:02:16 UTC
DuplicateProjectException
How do I get maven to do a clean compile of project D when I have the
following situation:
A -> B
C -> B
D -> A and D->C,
where letters are projects and arrows mean "module of"?
RE: DuplicateProjectException
Posted by Jörg Schaible <Jo...@Elsag-Solutions.com>.
Heinrich Nirschl wrote on Thursday, October 18, 2007 6:12 PM:
> On 10/18/07, Jason Nerothin <ja...@gmail.com> wrote:
>> Okay, so what I mean is that I have four complilation units: Unit A
>> has compile-time dependencies on B1 and B2 which in turn have a
>> compile-time dependency on unit C. "mvn compile" tries to figure out
>> "which" code to link against (B1->C or B2->C) and throws a
> DuplicateProjectException. Is such an
>> arrangement possible with maven or am I missing some larger point
>> about dependency management?
>
> The situation you describe is normally handled without any problem. In
> fact it is quite common that dependencies have common
> sub-dependencies, just think of C being a logging package for example.
>
> I don't know in which situations Maven throws a
> DuplicateProjectException (never saw this one myself). Its maybe
> easier to diagnose the problem if we see the poms.
In case of a copy & paste error. Copy an existing sub project, add it to the multi project build and forget to adjust the artifactId ... boom!
:)
- Jörg
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: DuplicateProjectException
Posted by Heinrich Nirschl <he...@gmail.com>.
On 10/18/07, Jason Nerothin <ja...@gmail.com> wrote:
> Okay, so what I mean is that I have four complilation units: Unit A has
> compile-time dependencies on B1 and B2 which in turn have a compile-time
> dependency on unit C. "mvn compile" tries to figure out "which" code to link
> against (B1->C or B2->C) and throws a DuplicateProjectException. Is such an
> arrangement possible with maven or am I missing some larger point about
> dependency management?
The situation you describe is normally handled without any problem. In
fact it is quite common that dependencies have common
sub-dependencies, just think of C being a logging package for example.
I don't know in which situations Maven throws a
DuplicateProjectException (never saw this one myself). Its maybe
easier to diagnose the problem if we see the poms.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: DuplicateProjectException
Posted by Heinrich Nirschl <he...@gmail.com>.
Hmm, thats still not clear since "module of" and "depends upon" are
totally different relationships.
B module of A means that in A's pom you have a <module>B</module>
whereas A depends on B means that in A's pom you have a
<dependency><artifactId>B</artifactId> ... </dependency>
On 10/16/07, Jason Nerothin <ja...@gmail.com> wrote:
> A -> B means "B is a module of A" or "A depends upon B"
>
> On 10/16/07, Wayne Fay <wa...@gmail.com> wrote:
> >
> > Its hard to tell from your email.. Are you saying A->B == A depends on
> > B? or B depends on A? Perhaps just use English to explain.
> >
> > Wayne
> >
> > On 10/16/07, Jason Nerothin <ja...@gmail.com> wrote:
> > > How do I get maven to do a clean compile of project D when I have the
> > > following situation:
> > >
> > > A -> B
> > >
> > > C -> B
> > >
> > > D -> A and D->C,
> > >
> > > where letters are projects and arrows mean "module of"?
> > >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> > For additional commands, e-mail: users-help@maven.apache.org
> >
> >
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: DuplicateProjectException
Posted by Jason Nerothin <ja...@gmail.com>.
A -> B means "B is a module of A" or "A depends upon B"
On 10/16/07, Wayne Fay <wa...@gmail.com> wrote:
>
> Its hard to tell from your email.. Are you saying A->B == A depends on
> B? or B depends on A? Perhaps just use English to explain.
>
> Wayne
>
> On 10/16/07, Jason Nerothin <ja...@gmail.com> wrote:
> > How do I get maven to do a clean compile of project D when I have the
> > following situation:
> >
> > A -> B
> >
> > C -> B
> >
> > D -> A and D->C,
> >
> > where letters are projects and arrows mean "module of"?
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>
Re: DuplicateProjectException
Posted by Wayne Fay <wa...@gmail.com>.
Its hard to tell from your email.. Are you saying A->B == A depends on
B? or B depends on A? Perhaps just use English to explain.
Wayne
On 10/16/07, Jason Nerothin <ja...@gmail.com> wrote:
> How do I get maven to do a clean compile of project D when I have the
> following situation:
>
> A -> B
>
> C -> B
>
> D -> A and D->C,
>
> where letters are projects and arrows mean "module of"?
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org