summaryrefslogtreecommitdiff
path: root/bfd/elfxx-mips.c
diff options
context:
space:
mode:
authorRichard Sandiford <rsandifo@nildram.co.uk>2011-01-22 10:16:28 +0000
committerRichard Sandiford <rsandifo@nildram.co.uk>2011-01-22 10:16:28 +0000
commit90a763964dba5318d091dc839bc139ba19bdd703 (patch)
tree6a7d9662eb24a112cce7dc1b1eb8897811026054 /bfd/elfxx-mips.c
parent406f217393fa9f9cd68c600ce672ad9808da69bf (diff)
downloadgdb-90a763964dba5318d091dc839bc139ba19bdd703.tar.gz
bfd/
* elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Ignore common sections too. ld/ * plugin.c (plugin_get_ir_dummy_bfd): Copy across the bfd's private data and GP size.
Diffstat (limited to 'bfd/elfxx-mips.c')
-rw-r--r--bfd/elfxx-mips.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/bfd/elfxx-mips.c b/bfd/elfxx-mips.c
index dcf6a9e7b11..d5e99bbb204 100644
--- a/bfd/elfxx-mips.c
+++ b/bfd/elfxx-mips.c
@@ -12597,8 +12597,11 @@ _bfd_mips_elf_merge_private_bfd_data (bfd *ibfd, bfd *obfd)
for (sec = ibfd->sections; sec != NULL; sec = sec->next)
{
/* Ignore synthetic sections and empty .text, .data and .bss sections
- which are automatically generated by gas. */
- if (strcmp (sec->name, ".reginfo")
+ which are automatically generated by gas. Also ignore fake
+ (s)common sections, since merely defining a common symbol does
+ not affect compatibility. */
+ if ((sec->flags & SEC_IS_COMMON) == 0
+ && strcmp (sec->name, ".reginfo")
&& strcmp (sec->name, ".mdebug")
&& (sec->size != 0
|| (strcmp (sec->name, ".text")