From 0910702c4d2cf9e8302b35c9519548726e1ac489 Mon Sep 17 00:00:00 2001 From: Szabolcs Nagy Date: Fri, 24 Jul 2015 09:57:32 +0100 Subject: [AArch64][BZ #17711] Fix extern protected data handling Fixes elf/tst-protected1a and elf/tst-protected1b tests. Depends on a gcc patch that makes protected visibility data non-local: https://gcc.gnu.org/ml/gcc-patches/2015-07/msg01871.html and on a binutils patch so R_*_GLOB_DAT relocs are used for it: https://sourceware.org/ml/binutils/2015-07/msg00246.html --- sysdeps/aarch64/dl-machine.h | 3 ++- sysdeps/aarch64/dl-sysdep.h | 2 ++ 2 files changed, 4 insertions(+), 1 deletion(-) (limited to 'sysdeps/aarch64') diff --git a/sysdeps/aarch64/dl-machine.h b/sysdeps/aarch64/dl-machine.h index 350d9879b2..217e1798c4 100644 --- a/sysdeps/aarch64/dl-machine.h +++ b/sysdeps/aarch64/dl-machine.h @@ -195,7 +195,8 @@ _dl_start_user: \n\ (type) == R_AARCH64_TLS_DTPREL || \ (type) == R_AARCH64_TLS_TPREL || \ (type) == R_AARCH64_TLSDESC) * ELF_RTYPE_CLASS_PLT) \ - | (((type) == R_AARCH64_COPY) * ELF_RTYPE_CLASS_COPY)) + | (((type) == R_AARCH64_COPY) * ELF_RTYPE_CLASS_COPY) \ + | (((type) == R_AARCH64_GLOB_DAT) * ELF_RTYPE_CLASS_EXTERN_PROTECTED_DATA)) #define ELF_MACHINE_JMP_SLOT R_AARCH64_JUMP_SLOT diff --git a/sysdeps/aarch64/dl-sysdep.h b/sysdeps/aarch64/dl-sysdep.h index 4f951def57..0bdbea651e 100644 --- a/sysdeps/aarch64/dl-sysdep.h +++ b/sysdeps/aarch64/dl-sysdep.h @@ -21,3 +21,5 @@ /* _dl_argv cannot be attribute_relro, because _dl_start_user might write into it after _dl_start returns. */ #define DL_ARGV_NOT_RELRO 1 + +#define DL_EXTERN_PROTECTED_DATA -- cgit 1.4.1