ant-ivy-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Altmann, Sebastian" <Sebastian.Altm...@isogmbh.de>
Subject AW: Including dependencies from external file
Date Tue, 14 Jul 2009 14:30:03 GMT


Thanks for that really fast answer Nicolas,

I'm using eclipse 3.4 and it tells me something like 
"... build path containing duplicate entry: /home/bla/bla.jar ...".

Maybe this is not because of just the same lib in two different
classpath containers, 
but same lib in same directory in two different classpath containers
causes the problem:

/home/asdf/lib/log4j.jar in classpath-container A
and
/some/other/path/log4j.jar in classpath-container B

Would work(?), but:

/home/asdf/lib/log4j.jar in classpath-container A
and
/home/asdf/lib/log4j.jar in classpath-container B

Would not work???

Your proposal of using different configs is a solution I thought about
too,
but it is not an option for this project,
because it is not possible for some complicated reasons depending on our
environment.
And after we plan to divide the project in the future (if there is some
time left) I'm pretty ok with 2 ivy files.


But now while I'm writing this message,
I got an idea:

If the eclipse duplicate build path error really only happens how I
assumed above (I will check this now), 
my solution would be to use 2 different settings-files (or maybe make
use of the new properties feature in ivyDE) that contain different
pathes to the local cache and it hopefully would work...




Le 8 juil. 09 à 16:38, Altmann, Sebastian a écrit :

> Hi everybody,
>
>
>
> maybe someone here has a hint for me:
>
>
>
> We have a software project which includes one ivy-file for Server and
> one for Webclient and also a separate buildfiles (don't ask, at the
> moment it is not possible to divide this project into two projects).
>
> To this point everything is ok,
>
> but now eclipse comes into play:
>
>
>
> I'm using the ivyDE plugin and after I got two ivy-files I want to add
> two libraries to build path
>
> one containing to dependencies in one ivy-file and the other ...
>
>
>
> In some cases this could work, but not when the ivy-files contain same
> libs,
>
> which happens permanently with libs like commons-collections.jar etc.
>
>
>
> For this reason I wanted an ivy file which includes all dependencies
> from the other two.
>
> Things like publishing are not interesting in this context,
>
> because this is done via ant and the Server or Webclient ivy-files.
>
> The only reason for my approach would be to prevent eclipse from
> displaying build path errors.

As far as I remember, Eclipse doesn't complain if two same jars are in  
to the classpath (Eclipse 3.4 or Eclipse 3.5 I think).

And actually you can use only one ivy file to declare two dependency  
set. Just define two configurations, a "webserver" one and a  
"webclient" one for instance. And then in your dependencies declare in  
which configuration they should be resolved.
Then in your build we will resolve against the same file but on  
different configurations. And in eclipse you will resolve both so Ivy  
will merge the two dependency sets.

Nicolas

>
>
>
>
>
> Mit freundlichen Grüßen
>
> Sebastian Altmann
> ____________________________________
> ISO Software Systeme GmbH
> Eichendorffstrasse 29
> 90491 Nürnberg
> Germany
>
> Tel.: +49/(911) - 99594-511
>
> mailto:sebastian.altmann@isogmbh.de
> <mailto:sebastian.altmann@isogmbh.de>
> http://www.isogmbh.de <http://www.isogmbh.de/>
>
> Amtsgericht Nürnberg HRB 18299
> Geschäftsführer: Harald Goeb
> Sitz: Nürnberg
>
>
>


Mime
View raw message