https://sourceware.org/bugzilla/show_bug.cgi?id=33350
Bug ID: 33350
Summary: Several readelf GOT tests FAIL
Product: binutils
Version: 2.46 (HEAD)
Status: NEW
Severity: normal
Priority: P2
Component: ld
Assignee: unassigned at sourceware dot org
Reporter: ro at gcc dot gnu.org
CC: hjl.tools at gmail dot com
Target Milestone: ---
Target: i386-pc-solaris2.11, amd64-pc-solaris2.11,
amd64-pc-freebsd14.0
Several of the new readelf GOT tests FAIL on non-Linux x86 targets (Solaris,
FreeBSD).
* FAIL: Build libgot-1.so
on both Solaris/amd64 and i386.
The failure mode is equivalent on both:
./ld-new: target elf64-x86-64 not found
./ld-new: target elf32-i386 not found
The Solaris tests need to use a different linker emulation, so needs to
append _sol2 again. The same issue already occured in ld-elf/elf.exp.
I've now introduced a proc to handle this, part of the attached patch.
While this fixes the build failures, I now get regexp_diff failures:
i386:
regexp_diff match failure
regexp "^Relocation section '.rel.dyn' at offset 0x128 contains 1 entry:$"
line "Relocation section '.rel.dyn' at offset 0x15c contains 1 entry:"
regexp_diff match failure
regexp "^0+2001fc 00000206 R_386_GLOB_DAT 00000000 foo$"
line "0020023c 00000406 R_386_GLOB_DAT 00000000 foo"
regexp_diff match failure
regexp "^Relocation section '.rel.plt' at offset 0x130 contains 1 entry:$"
line "Relocation section '.rel.plt' at offset 0x164 contains 1 entry:"
regexp_diff match failure
regexp "^0+20020c 00000307 R_386_JUMP_SLOT 00000000 bar$"
line "00200238 00000507 R_386_JUMP_SLOT 00000000 bar"
output is
Relocation section '.rel.dyn' at offset 0x15c contains 1 entry:
Offset Info Type Sym. Value Symbol's Name
0020023c 00000406 R_386_GLOB_DAT 00000000 foo
Relocation section '.rel.plt' at offset 0x164 contains 1 entry:
Offset Info Type Sym. Value Symbol's Name
00200238 00000507 R_386_JUMP_SLOT 00000000 bar
64-bit:
regexp_diff match failure
regexp "^0+200340 0000000200000006 R_X86_64_GLOB_DAT 0000000000000000 foo
\+ 0$"
line "0000000000200380 0000000400000006 R_X86_64_GLOB_DAT
0000000000000000 foo + 0"
regexp_diff match failure
regexp "^Relocation section '.rela.plt' at offset 0x1d0 contains 1 entry:$"
line "Relocation section '.rela.plt' at offset 0x218 contains 1 entry:"
regexp_diff match failure
regexp "^0+200360 0000000300000007 R_X86_64_JUMP_SLOT 0000000000000000 bar
\+ 0$"
line "00000000002003a0 0000000500000007 R_X86_64_JUMP_SLOT
0000000000000000 bar + 0"
output is
Relocation section '.rela.dyn' at offset 0x200 contains 1 entry:
Offset Info Type Symbol's Value
Symbol's Name + Addend
0000000000200380 0000000400000006 R_X86_64_GLOB_DAT 0000000000000000 foo
+ 0
Relocation section '.rela.plt' at offset 0x218 contains 1 entry:
Offset Info Type Symbol's Value
Symbol's Name + Addend
00000000002003a0 0000000500000007 R_X86_64_JUMP_SLOT 0000000000000000 bar
+ 0
The patch relaxes the patterns to cope with this, but afterwards the tests
still fail checking the readelf -aW output. I have a hard time telling if
those differences are benign, so I'm attaching the i386 and amd64 versions
of libgot-1.so for inspection.
* FAIL: Build libgot-1-x32.so
This fails on both Solaris/amd64 and FreeBSD/amd64.
Assembler messages:
Fatal error: no compiled in support for 32bit x86_64
Since the x32 ABI is Linux-only AFAIK, I've restricted this test to
Linux/x86 as other x32 tests do.
* Besides, the "Build libgot-1.so" test uses the same test name for both
32 and 64-bit, making it difficult to distinguish the two.
--
You are receiving this mail because:
You are on the CC list for the bug.