[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug-gsl] Re: library dependencies and --as-needed

From: Alan Modra
Subject: [Bug-gsl] Re: library dependencies and --as-needed
Date: Fri, 30 Jan 2009 15:20:41 +1030
User-agent: Mutt/1.5.17+20080114 (2008-01-14)

On Thu, Jan 29, 2009 at 03:26:19PM +0000, Brian Gough wrote:
> It seems like it would work if the search with --as-needed was
> recursive, is there any conceptual reason for it not to do that?

It just happened that way because that's what we do for libs brought
in only because they are mentioned as dependencies of other libs that
ld is linking against.  ie. if we have

       /  \
     libx liby

and we link app just against libx and liby, you won't get a DT_NEEDED
tag in app for libz unless app references some symbol in libz
directly.  The idea is that if app does reference libz, then we want
to protect against some newer liby being installed that no longer
needs libz.

--as-needed is really a different case, and I don't see why we
shouldn't do as you are asking.  I've said as much before,
and a google search turns up at least one bug report about this.

Any dissenting opinions on this issue?

Alan Modra
Australia Development Lab, IBM

reply via email to

[Prev in Thread] Current Thread [Next in Thread]