This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [i386] Why g++ _always_ link an executable with libm.so?


On Wed, 2005-01-05 at 13:48 -0500, Andrew Pinski wrote:
> Again why are you complaining when a good dynamic loader will not load
> the needed libraries unless they are really needed?

You can't do that for ELF, you have no idea what libraries symbols are
meant to come from. The NEEDED entries in a binary are how the loader
knows what's needed and what's not, as the name implies. There's no way
to strip these entries once the binary has been built (except taking
them away one at a time and seeing if anything breaks ...) so it's
better if the compiler/linker does it.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]