[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug ld/22909] Expand --warn-shared-textrel support to all executables,
From: |
slyfox at inbox dot ru |
Subject: |
[Bug ld/22909] Expand --warn-shared-textrel support to all executables, not only PIC objects |
Date: |
Tue, 08 May 2018 22:30:18 +0000 |
https://sourceware.org/bugzilla/show_bug.cgi?id=22909
--- Comment #2 from Sergei Trofimovich <slyfox at inbox dot ru> ---
I was not able to force x86 targets to generate TEXTREL executables.
Best I could do is to emit pseudo textrel but it does not cause TEXTREL section
creation:
// a.c
#include <stdio.h>
int _start() {
__asm__ volatile (
".Ltext_reloc:"
".reloc .Ltext_reloc - _start, R_386_32, printf\n"
".long 0x90909090\n"
);
}
$ gcc -m32 a.c -O2 -o a -rdynamic -no-pie -nostdlib -lc -Wl,-q
Is there a way to force printf symbol ot be resolved to absolute address
instead of .plt?
--
You are receiving this mail because:
You are on the CC list for the bug.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Bug ld/22909] Expand --warn-shared-textrel support to all executables, not only PIC objects,
slyfox at inbox dot ru <=