diff options
author | Martin Liska <mliska@suse.cz> | 2019-08-16 13:14:36 +0200 |
---|---|---|
committer | Martin Liska <mliska@suse.cz> | 2019-08-16 13:14:36 +0200 |
commit | b4c555cfc48689d45481effff23c9017a4f3557f (patch) | |
tree | 76f2178975c851a0e79f65b265a02ddfa3a8caa3 /bfd/linker.c | |
parent | aa7ca1bb443e8c2baad17392f395d1556fecfafa (diff) | |
download | gdb-b4c555cfc48689d45481effff23c9017a4f3557f.zip gdb-b4c555cfc48689d45481effff23c9017a4f3557f.tar.gz gdb-b4c555cfc48689d45481effff23c9017a4f3557f.tar.bz2 |
Fix detection of missing plugin for LTO objects.
2019-08-16 Martin Liska <mliska@suse.cz>
PR ld/24912
* elflink.c: Report error only for not relocatable.
* linker.c (_bfd_generic_link_add_one_symbol): Do not handle
here lto_slim_object as it's handled in caller.
2019-08-16 Martin Liska <mliska@suse.cz>
PR ld/24912
* object.cc (big_endian>::do_layout): Do not report error,
but only set a flag.
(big_endian>::do_add_symbols): Report error only for when
relocatable.
Diffstat (limited to 'bfd/linker.c')
-rw-r--r-- | bfd/linker.c | 24 |
1 files changed, 6 insertions, 18 deletions
diff --git a/bfd/linker.c b/bfd/linker.c index edbd0a7..1b71fcf 100644 --- a/bfd/linker.c +++ b/bfd/linker.c @@ -1421,24 +1421,12 @@ _bfd_generic_link_add_one_symbol (struct bfd_link_info *info, else if (bfd_is_com_section (section)) { row = COMMON_ROW; - static bfd_boolean report_plugin_err = TRUE; - if (!bfd_link_relocatable (info) && report_plugin_err) - { - if (abfd->lto_slim_object) - { - report_plugin_err = FALSE; - _bfd_error_handler - (_("%pB: plugin needed to handle lto object"), abfd); - } - else if (name[0] == '_' - && name[1] == '_' - && strcmp (name + (name[2] == '_'), "__gnu_lto_slim") == 0) - { - report_plugin_err = FALSE; - _bfd_error_handler - (_("%pB: plugin needed to handle lto object"), abfd); - } - } + if (!bfd_link_relocatable (info) + && name[0] == '_' + && name[1] == '_' + && strcmp (name + (name[2] == '_'), "__gnu_lto_slim") == 0) + _bfd_error_handler + (_("%pB: plugin needed to handle lto object"), abfd); } else row = DEF_ROW; |