mirror of
https://sourceware.org/git/binutils-gdb.git
synced 2025-02-05 12:53:16 +08:00
GOT32 relocations are allowed since absolute value + addend is stored in the GOT slot. Tested on glibc 2.35 build with GCC 11.2 and -Os. bfd/ PR ld/28870 * elfxx-x86.c (_bfd_elf_x86_valid_reloc_p): Also allow GOT32 relocations. ld/ PR ld/28870 * testsuite/ld-i386/i386.exp: Run pr28870. * testsuite/ld-i386/pr28870.d: New file. * testsuite/ld-i386/pr28870.s: Likewise.
7 lines
88 B
ArmAsm
7 lines
88 B
ArmAsm
.text
|
|
.globl _start
|
|
_start:
|
|
addl foo@GOT(%ebx), %eax
|
|
cmpl $0, foo@GOT(%ebx)
|
|
foo = 2
|