aboutsummaryrefslogtreecommitdiff
path: root/bfd
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2020-04-18 15:57:07 +0930
committerAlan Modra <amodra@gmail.com>2020-04-20 08:14:42 +0930
commit2efec98b28bbc89fc8e062709c7e28cc8a56ee40 (patch)
tree4c52288432a90138eab7e5d15ac38d6d7ee49cda /bfd
parent45e1f031e823abf0fb233b3da6da099417e65bd8 (diff)
downloadgdb-2efec98b28bbc89fc8e062709c7e28cc8a56ee40.zip
gdb-2efec98b28bbc89fc8e062709c7e28cc8a56ee40.tar.gz
gdb-2efec98b28bbc89fc8e062709c7e28cc8a56ee40.tar.bz2
PowerPC64: remove empty .rela.dyn (.rela.branch_lt)
Stripping .rela.branch_lt is easy enough but messes with the testsuite due to stub symbols (that use section id) changing. Tests that run on more than one target variant can be tricky to fix, this renaming happened to work. bfd/ * elf64-ppc.c (ppc64_elf_size_stubs): Strip relbrlt too. ld/ * testsuite/ld-powerpc/tlsopt5.s: Rename foo to aaaaa. * testsuite/ld-powerpc/tlsopt5.d: Adjust to suit. * testsuite/ld-powerpc/tlsopt6.d: Likewise.
Diffstat (limited to 'bfd')
-rw-r--r--bfd/ChangeLog4
-rw-r--r--bfd/elf64-ppc.c2
2 files changed, 6 insertions, 0 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index 9d5f1cb..f88e883 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,3 +1,7 @@
+2020-04-20 Alan Modra <amodra@gmail.com>
+
+ * elf64-ppc.c (ppc64_elf_size_stubs): Strip relbrlt too.
+
2020-04-18 Alan Modra <amodra@gmail.com>
* section.c (bfd_is_const_section): Correct test for special
diff --git a/bfd/elf64-ppc.c b/bfd/elf64-ppc.c
index 63de3ab..53e5d91 100644
--- a/bfd/elf64-ppc.c
+++ b/bfd/elf64-ppc.c
@@ -13772,6 +13772,8 @@ ppc64_elf_size_stubs (struct bfd_link_info *info)
}
maybe_strip_output (info, htab->brlt);
+ if (htab->relbrlt != NULL)
+ maybe_strip_output (info, htab->relbrlt);
if (htab->glink_eh_frame != NULL)
maybe_strip_output (info, htab->glink_eh_frame);