Fix non-plugin warning symbol handling
PR ld/16746 include/ * bfdlink.h (struct bfd_link_info): Add lto_plugin_active. bfd/ * linker.c (_bfd_generic_link_add_one_symbol <WARN>): Handle !lto_plugin_active. ld/ * plugin.c (plugin_load_plugins): Set link_info.lto_plugin_active.
This commit is contained in:
parent
d769e349bc
commit
61f41c3c24
3 changed files with 7 additions and 1 deletions
|
@ -1806,7 +1806,9 @@ _bfd_generic_link_add_one_symbol (struct bfd_link_info *info,
|
|||
case WARN:
|
||||
/* Warn if this symbol has been referenced already from non-IR,
|
||||
otherwise add a warning. */
|
||||
if (h->non_ir_ref)
|
||||
if ((!info->lto_plugin_active
|
||||
&& (h->u.undef.next != NULL || info->hash->undefs_tail == h))
|
||||
|| h->non_ir_ref)
|
||||
{
|
||||
if (! (*info->callbacks->warning) (info, string, h->root.string,
|
||||
hash_entry_bfd (h), NULL, 0))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue