diff options
Diffstat (limited to 'ld/plugin.c')
-rw-r--r-- | ld/plugin.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/ld/plugin.c b/ld/plugin.c index 79b39e8..c4337d9 100644 --- a/ld/plugin.c +++ b/ld/plugin.c @@ -292,6 +292,9 @@ asymbol_from_plugin_symbol (bfd *abfd, asymbol *asym, flags = BSF_GLOBAL; section = bfd_com_section_ptr; asym->value = ldsym->size; + /* For ELF targets, set alignment of common symbol to 1. */ + if (bfd_get_flavour (abfd) == bfd_target_elf_flavour) + ((elf_symbol_type *) asym)->internal_elf_sym.st_value = 1; break; default: |