Current-Users archive

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

Re: link problems



On Fri, Oct 11, 2013 at 10:02:11PM +0100, David Laight wrote:
> What does that change do?
> 
> If you link a program with -lcurses you don't want a DT_NEEDED entry
> for libtemcap.so whether or not the program directly references
> anything in libtermcap.so.

You tell it to link against libcurses.so and it gets a DT_NEEDED for
libcurses.so - no matter wether a symbol is referenced from there or
not.

However, I have been unable to make ld not emit a DT_NEEDED for
libterminfo, no matter what options I tried, so the test program ends
up with:

Dynamic Section:
  NEEDED               libcurses.so.7
  NEEDED               libgcc_s.so.1
  NEEDED               libc.so.12
  NEEDED               libterminfo.so.1


Let us move technical details of this fix to tech-toolchain (there already
is a thread started for this).

Martin


Home | Main Index | Thread Index | Old Index