https://sourceware.org/bugzilla/show_bug.cgi?id=22115
Bug ID: 22115
Summary: ld: read-only segment has dynamic relocations.
Product: binutils
Version: 2.30 (HEAD)
Status: NEW
Severity: normal
Priority: P2
Component: ld
Assignee: unassigned at sourceware dot org
Reporter: hjl.tools at gmail dot com
Target Milestone: ---
Target: x86
[hjl@gnu-tools-1 ld]$ cat x.c
extern int __ehdr_start __attribute__ ((weak));
int *
_start (void)
{
return &__ehdr_start;
}
[hjl@gnu-tools-1 ld]$ gcc -c -fPIE -O2 x.c
[hjl@gnu-tools-1 ld]$ ld -pie x.o -z text --no-dynamic-linker
ld: x.o: warning: relocation against `__ehdr_start' in readonly section `.text'
ld: read-only segment has dynamic relocations.
[hjl@gnu-tools-1 ld]$
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
bug-binutils mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/bug-binutils