forked from Imagelibrary/binutils-gdb
PR ld/20276: Set non_ir_ref on common symbol
Also, don't check alignment on symbol from plugin dummy input. bfd/ PR ld/20276 * elflink.c (elf_link_add_object_symbols): Don't check alignment on symbol from plugin dummy input. ld/ PR ld/20276 * plugin.c (plugin_notice): Set non_ir_ref on common symbols. * testsuite/ld-plugin/lto.exp (lto_link_tests): Add test for PR ld/20276. (lto_run_tests): Likewise. * testsuite/ld-plugin/pass.out: New file. * testsuite/ld-plugin/pr20276a.c: Likewise. * testsuite/ld-plugin/pr20276b.c: Likewise.
This commit is contained in:
@@ -4556,7 +4556,8 @@ error_free_dyn:
|
||||
|
||||
symbol_align = ffs (h->root.u.def.value) - 1;
|
||||
if (h->root.u.def.section->owner != NULL
|
||||
&& (h->root.u.def.section->owner->flags & DYNAMIC) == 0)
|
||||
&& (h->root.u.def.section->owner->flags
|
||||
& (DYNAMIC | BFD_PLUGIN)) == 0)
|
||||
{
|
||||
normal_align = h->root.u.def.section->alignment_power;
|
||||
if (normal_align > symbol_align)
|
||||
|
||||
Reference in New Issue
Block a user