[PATCH][ARM] set DF_STATIC_TLS when emitting IE relocs
Kyle McMartin
kmcmarti@redhat.com
Mon May 12 17:19:00 GMT 2014
Similarly to the AArch64 patch, set DF_STATIC_TLS for consistency with
other architectures when we emit IE relocs in a shared library.
2014-05-12 Kyle McMartin <kyle@redhat.com>
* elf32-arm.c (elf32_arm_check_relocs): Set DF_STATIC_TLS when emitting
initial-exec relocs when not linking an executable.
---
bfd/elf32-arm.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/bfd/elf32-arm.c b/bfd/elf32-arm.c
index 526d4f8..d5dcc83 100644
--- a/bfd/elf32-arm.c
+++ b/bfd/elf32-arm.c
@@ -12705,6 +12705,9 @@ elf32_arm_check_relocs (bfd *abfd, struct bfd_link_info *info,
default: tls_type = GOT_NORMAL; break;
}
+ if (!info->executable && (tls_type & GOT_TLS_IE))
+ info->flags |= DF_STATIC_TLS;
+
if (h != NULL)
{
h->got.refcount++;
--
1.9.0
More information about the Binutils
mailing list