From 1a4d5765cd2664be2b8639ec4cec7b75e7804fa4 Mon Sep 17 00:00:00 2001 From: kettenis Date: Thu, 23 Jun 2016 12:02:18 +0000 Subject: [PATCH] Use SYMBOL_CALLS_LOCAL() to determine whether we can drop relocations for a symbol such that hidden symbols get handled properly. Gets rid of the spurious DT_TEXTREL entries seen with (typically) C++ code. ok deraadt@, guenther@ --- gnu/usr.bin/binutils-2.17/bfd/elfxx-sparc.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/gnu/usr.bin/binutils-2.17/bfd/elfxx-sparc.c b/gnu/usr.bin/binutils-2.17/bfd/elfxx-sparc.c index 11a7f8d9302..643a028cfbe 100644 --- a/gnu/usr.bin/binutils-2.17/bfd/elfxx-sparc.c +++ b/gnu/usr.bin/binutils-2.17/bfd/elfxx-sparc.c @@ -2003,9 +2003,7 @@ allocate_dynrelocs (struct elf_link_hash_entry *h, PTR inf) if (info->shared) { - if (h->def_regular - && (h->forced_local - || info->symbolic)) + if (SYMBOL_CALLS_LOCAL (info, h)) { struct _bfd_sparc_elf_dyn_relocs **pp; -- 2.20.1