diff options
author | Andreas Schwab <schwab@suse.de> | 2023-09-21 16:49:41 +0200 |
---|---|---|
committer | Andreas Schwab <schwab@suse.de> | 2023-09-25 12:36:58 +0200 |
commit | 7345d05aafde53a48d5a587a6d9c1778db78e0f3 (patch) | |
tree | 2402f4d9ecda856d80e8fc4f1ce1c54b8609baab /ld/testsuite/ld-elf | |
parent | a47d304b1229ecf8912fac17ee9c48d1bf3c729a (diff) | |
download | gdb-7345d05aafde53a48d5a587a6d9c1778db78e0f3.zip gdb-7345d05aafde53a48d5a587a6d9c1778db78e0f3.tar.gz gdb-7345d05aafde53a48d5a587a6d9c1778db78e0f3.tar.bz2 |
RISC-V: Protect .got with relro
Move .got before .data so that it can be protected with -zrelro. Also
separate .got.plt from .got if -znow is not in effect; the first two words
of .got.plt are placed within the relro region.
ld:
PR ld/30877
* emulparams/elf32lriscv-defs.sh (DATA_GOT, SEPARATE_GOTPLT):
Define.
* emulparams/elf64lriscv-defs.sh (SEPARATE_GOTPLT): Define.
* testsuite/ld-elf/binutils.exp (binutils_test): Remove riscv*-*-*
from relro_got expression.
Diffstat (limited to 'ld/testsuite/ld-elf')
-rw-r--r-- | ld/testsuite/ld-elf/binutils.exp | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/ld/testsuite/ld-elf/binutils.exp b/ld/testsuite/ld-elf/binutils.exp index 674e8e9..b38e29e 100644 --- a/ld/testsuite/ld-elf/binutils.exp +++ b/ld/testsuite/ld-elf/binutils.exp @@ -95,7 +95,6 @@ proc binutils_test { prog_name ld_options test {test_name ""} {readelf_options " || [istarget "mips*-*-*"] \ || [istarget "nios2*-*-*"] \ || [istarget "or1k-*-*"] \ - || [istarget "riscv*-*-*"] \ || [istarget "sh*-*-*"] \ || [istarget "x86_64-*-rdos*"])] # Check if GNU_RELRO segment is generated. |