https://sourceware.org/bugzilla/show_bug.cgi?id=23238
Bug ID: 23238
Summary: Missing ELFOSABI_GNU with IFUNC
Product: binutils
Version: 2.31 (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_64-*-*, i?86-*-*
[hjl@gnu-cfl-1 ld]$ cat x.s
.text
.type do_it_ifunc, @function
do_it_ifunc:
ret
.size do_it_ifunc, .-do_it_ifunc
.type resolve_do_it, @function
resolve_do_it:
leaq do_it_ifunc(%rip), %rax
ret
.size resolve_do_it, .-resolve_do_it
.globl do_it
.type do_it, @gnu_indirect_function
.set do_it,resolve_do_it
[hjl@gnu-cfl-1 ld]$ gcc -c x.s
[hjl@gnu-cfl-1 ld]$ ld -shared x.o
[hjl@gnu-cfl-1 ld]$ readelf -h a.out
ELF Header:
Magic: 7f 45 4c 46 02 01 01 00 00 00 00 00 00 00 00 00
Class: ELF64
Data: 2's complement, little endian
Version: 1 (current)
OS/ABI: UNIX - System V
^^^^^^^^^^^^ This should be GNU.
ABI Version: 0
Type: DYN (Shared object file)
Machine: Advanced Micro Devices X86-64
Version: 0x1
Entry point address: 0x1000
Start of program headers: 64 (bytes into file)
Start of section headers: 12840 (bytes into file)
Flags: 0x0
Size of this header: 64 (bytes)
Size of program headers: 56 (bytes)
Number of program headers: 6
Size of section headers: 64 (bytes)
Number of section headers: 11
Section header string table index: 10
[hjl@gnu-cfl-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