You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by youhaodeyi <yo...@gmail.com> on 2008/10/03 04:56:33 UTC

Can't Maven handle dependendies recursively?

I set up a maven project "P1" which depends on the project "P2". P2 includes
several dependencies which are used in P1. In this case, I must add these
dependencies in P1 too. If not, I will fail to build P1. How can I let maven
deal with this recursive dependencies?
-- 
View this message in context: http://www.nabble.com/Can%27t-Maven-handle-dependendies-recursively--tp19791304p19791304.html
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Can't Maven handle dependendies recursively?

Posted by Baptiste MATHUS <bm...@batmat.net>.
What's the output of "mvn dependency:tree", does the tree you see correctly
display the dependency you're expecting?

Cheers

2008/10/4 youhaodeyi <yo...@gmail.com>

>
> I have checked the P2 and it can be built successfully.
>
>
> Jörg Schaible-2 wrote:
> >
> > youhaodeyi wrote:
> >
> >>
> >> I didn't define the scope. It should be the default value.
> >
> > Then something is wrong with your POM for P2 ...
> >
> >>
> >> Wendy Smoak-3 wrote:
> >>>
> >>> On Thu, Oct 2, 2008 at 7:56 PM, youhaodeyi <yo...@gmail.com>
> wrote:
> >>>> I set up a maven project "P1" which depends on the project "P2". P2
> >>>> includes
> >>>> several dependencies which are used in P1. In this case, I must add
> >>>> these dependencies in P1 too. If not, I will fail to build P1. How can
> >>>> I
> >>>> let maven
> >>>> deal with this recursive dependencies?
> >>>
> >>> How are the dependencies declared in P2?  If they are in the default
> >>> compile scope, they should be transitive (so P1 should compile.)
> >>>
> >>> --
> >>> Wendy
> >>>
> >>> ---------------------------------------------------------------------
> >>> 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
> >
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/Can%27t-Maven-handle-dependendies-recursively--tp19791304p19809831.html
> Sent from the Maven - Users mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>


-- 
Baptiste <Batmat> MATHUS - http://batmat.net
Sauvez un arbre,
Mangez un castor !

Re: Can't Maven handle dependendies recursively?

Posted by Baptiste MATHUS <ml...@batmat.net>.
What's the output of "mvn dependency:tree", does the tree you see correctly
display the dependency you're expecting?

2008/10/4 youhaodeyi <yo...@gmail.com>

>
> I have checked the P2 and it can be built successfully.
>
>
> Jörg Schaible-2 wrote:
> >
> > youhaodeyi wrote:
> >
> >>
> >> I didn't define the scope. It should be the default value.
> >
> > Then something is wrong with your POM for P2 ...
> >
> >>
> >> Wendy Smoak-3 wrote:
> >>>
> >>> On Thu, Oct 2, 2008 at 7:56 PM, youhaodeyi <yo...@gmail.com>
> wrote:
> >>>> I set up a maven project "P1" which depends on the project "P2". P2
> >>>> includes
> >>>> several dependencies which are used in P1. In this case, I must add
> >>>> these dependencies in P1 too. If not, I will fail to build P1. How can
> >>>> I
> >>>> let maven
> >>>> deal with this recursive dependencies?
> >>>
> >>> How are the dependencies declared in P2?  If they are in the default
> >>> compile scope, they should be transitive (so P1 should compile.)
> >>>
> >>> --
> >>> Wendy
> >>>
> >>> ---------------------------------------------------------------------
> >>> 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
> >
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/Can%27t-Maven-handle-dependendies-recursively--tp19791304p19809831.html
> Sent from the Maven - Users mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>


-- 
Baptiste <Batmat> MATHUS - http://batmat.net
Sauvez un arbre,
Mangez un castor !

Re: Can't Maven handle dependendies recursively?

Posted by youhaodeyi <yo...@gmail.com>.
I have checked the P2 and it can be built successfully.


Jörg Schaible-2 wrote:
> 
> youhaodeyi wrote:
> 
>> 
>> I didn't define the scope. It should be the default value.
> 
> Then something is wrong with your POM for P2 ...
> 
>> 
>> Wendy Smoak-3 wrote:
>>> 
>>> On Thu, Oct 2, 2008 at 7:56 PM, youhaodeyi <yo...@gmail.com> wrote:
>>>> I set up a maven project "P1" which depends on the project "P2". P2
>>>> includes
>>>> several dependencies which are used in P1. In this case, I must add
>>>> these dependencies in P1 too. If not, I will fail to build P1. How can
>>>> I
>>>> let maven
>>>> deal with this recursive dependencies?
>>> 
>>> How are the dependencies declared in P2?  If they are in the default
>>> compile scope, they should be transitive (so P1 should compile.)
>>> 
>>> --
>>> Wendy
>>> 
>>> ---------------------------------------------------------------------
>>> 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
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Can%27t-Maven-handle-dependendies-recursively--tp19791304p19809831.html
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Can't Maven handle dependendies recursively?

Posted by Jörg Schaible <jo...@gmx.de>.
youhaodeyi wrote:

> 
> I didn't define the scope. It should be the default value.

Then something is wrong with your POM for P2 ...

> 
> Wendy Smoak-3 wrote:
>> 
>> On Thu, Oct 2, 2008 at 7:56 PM, youhaodeyi <yo...@gmail.com> wrote:
>>> I set up a maven project "P1" which depends on the project "P2". P2
>>> includes
>>> several dependencies which are used in P1. In this case, I must add
>>> these dependencies in P1 too. If not, I will fail to build P1. How can I
>>> let maven
>>> deal with this recursive dependencies?
>> 
>> How are the dependencies declared in P2?  If they are in the default
>> compile scope, they should be transitive (so P1 should compile.)
>> 
>> --
>> Wendy
>> 
>> ---------------------------------------------------------------------
>> 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: Can't Maven handle dependendies recursively?

Posted by youhaodeyi <yo...@gmail.com>.
I didn't define the scope. It should be the default value.

Wendy Smoak-3 wrote:
> 
> On Thu, Oct 2, 2008 at 7:56 PM, youhaodeyi <yo...@gmail.com> wrote:
>> I set up a maven project "P1" which depends on the project "P2". P2
>> includes
>> several dependencies which are used in P1. In this case, I must add these
>> dependencies in P1 too. If not, I will fail to build P1. How can I let
>> maven
>> deal with this recursive dependencies?
> 
> How are the dependencies declared in P2?  If they are in the default
> compile scope, they should be transitive (so P1 should compile.)
> 
> -- 
> Wendy
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Can%27t-Maven-handle-dependendies-recursively--tp19791304p19793666.html
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Can't Maven handle dependendies recursively?

Posted by Wendy Smoak <ws...@gmail.com>.
On Thu, Oct 2, 2008 at 7:56 PM, youhaodeyi <yo...@gmail.com> wrote:
> I set up a maven project "P1" which depends on the project "P2". P2 includes
> several dependencies which are used in P1. In this case, I must add these
> dependencies in P1 too. If not, I will fail to build P1. How can I let maven
> deal with this recursive dependencies?

How are the dependencies declared in P2?  If they are in the default
compile scope, they should be transitive (so P1 should compile.)

-- 
Wendy

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org