Display the reference causing a shared library to be needed
authorAlan Modra <amodra@gmail.com>
Wed, 22 Jan 2014 05:35:12 +0000 (16:05 +1030)
committerAlan Modra <amodra@gmail.com>
Wed, 22 Jan 2014 05:51:34 +0000 (16:21 +1030)
commit16e4ecc0dbe114cfc97fe2cd32a035ae4c37f22b
treea48afd646fe4928d6546cc9c25fba25543fbcdb4
parentcda796e168a389624b4e06031922bf5eaf0b6f51
Display the reference causing a shared library to be needed

Adds a section for --as-needed libraries to a linker map file, similar
to what we do for archive libraries.

bfd/
* elflink.c (elf_link_add_object_symbols): Call minfo for --as-needed.
ld/
* ldlang.c (asneeded_list_head, asneeded_list_tail): New vars.
(lang_init): Initialise them.
(lang_print_asneeded): New function.
(lang_process): Call lang_print_asneeded.
* ldlang.h (struct asneeded_minfo): New.
(asneeded_list_tail): Declare.
* ldmain.c (add_archive_element): Improve archive map heading.
* ldmisc.c (minfo): Stash --as-needed info.
bfd/ChangeLog
bfd/elflink.c
ld/ChangeLog
ld/ldlang.c
ld/ldlang.h
ld/ldmain.c
ld/ldmisc.c