https://sourceware.org/bugzilla/show_bug.cgi?id=28488
Bug ID: 28488
Summary: phdr[6]: unknown object file note type 32 with owner
name '' at offset 48
Product: elfutils
Version: unspecified
Status: UNCONFIRMED
S
https://sourceware.org/bugzilla/show_bug.cgi?id=28488
Martin Liska changed:
What|Removed |Added
CC||mjw at fedoraproject dot org
--- Comme
https://sourceware.org/bugzilla/show_bug.cgi?id=28488
Mark Wielaard changed:
What|Removed |Added
CC|mjw at fedoraproject dot org |mark at klomp dot org
--- Comm
https://sourceware.org/bugzilla/show_bug.cgi?id=28488
--- Comment #3 from Martin Liska ---
F="-O2 -g -Wall -fuse-ld=gold" && export CFLAGS="$F" && export CXXFLAGS="$F" &&
export LDFLAGS="$F" && ./configure --enable-maintainer-mode
make && make check
--
You are receiving this mail because:
You a
https://sourceware.org/bugzilla/show_bug.cgi?id=28488
--- Comment #4 from Martin Liska ---
$ wget https://splichal.eu/tmp/addr2line
$ ./elflint --quiet --gnu-ld addr2line
phdr[6]: unknown object file note type 32 with owner name '' at offset 48
phdr[6]: extra 72 bytes after last note
--
You are
https://sourceware.org/bugzilla/show_bug.cgi?id=28488
--- Comment #5 from Martin Liska ---
Minimal reproducer:
$ echo 'main() { return 0; }' | gcc -x c - -fuse-ld=gold && ./elflint --gnu-ld
a.out
:1:1: warning: return type defaults to ‘int’ [-Wimplicit-int]
phdr[6]: unknown object file note type
https://sourceware.org/bugzilla/show_bug.cgi?id=28488
--- Comment #6 from Mark Wielaard ---
So with on fedora 34, x86_64:
gcc (GCC) 11.2.1 20210728 (Red Hat 11.2.1-1)
GNU gold (version 2.35.2-6.fc34) 1.16
eu-elflint (elfutils) 0.185
$ echo 'int main() { return 0; }' | gcc -x c - -fuse-ld=gold &
https://sourceware.org/bugzilla/show_bug.cgi?id=28488
--- Comment #7 from Mark Wielaard ---
The addr2line binary from comment #4 has two phdr NOTE segments:
$ eu-elflint --quiet --gnu-ld addr2line
phdr[6]: unknown object file note type 32 with owner name '' at offset 48
phdr[6]: extra 72 bytes a
https://sourceware.org/bugzilla/show_bug.cgi?id=28488
--- Comment #8 from Martin Liska ---
> There are two phdr PT_NOTE segments because they have different alignments
> (05 has alignment 8 and covers .note.gnu.property, 06 has alignment 8
06 has alignment 0x4, right?
--
You are receiving this
https://sourceware.org/bugzilla/show_bug.cgi?id=28488
--- Comment #9 from Mark Wielaard ---
So the real difference is that with the Fedora the .note.gnu.property has
alignment 4 and so it gets merged with the other (allocated) note sections. But
the opensuse version .note.gnu.property has alignme
https://sourceware.org/bugzilla/show_bug.cgi?id=28488
--- Comment #10 from Mark Wielaard ---
(In reply to Martin Liska from comment #8)
> > There are two phdr PT_NOTE segments because they have different alignments
> > (05 has alignment 8 and covers .note.gnu.property, 06 has alignment 8
>
> 06
https://sourceware.org/bugzilla/show_bug.cgi?id=28488
--- Comment #11 from Martin Liska ---
(In reply to Mark Wielaard from comment #9)
> So the real difference is that with the Fedora the .note.gnu.property has
> alignment 4 and so it gets merged with the other (allocated) note sections.
> But t
https://sourceware.org/bugzilla/show_bug.cgi?id=28488
--- Comment #12 from Martin Liska ---
(In reply to Martin Liska from comment #11)
> (In reply to Mark Wielaard from comment #9)
> > So the real difference is that with the Fedora the .note.gnu.property has
> > alignment 4 and so it gets merged
https://sourceware.org/bugzilla/show_bug.cgi?id=28488
--- Comment #13 from Martin Liska ---
Note
https://github.com/bminor/binutils-gdb/blob/master/gas/config/tc-i386.c#L9083
shows that alignment should be equal to 8 for ELFCLASS64.
--
You are receiving this mail because:
You are on the CC list
https://sourceware.org/bugzilla/show_bug.cgi?id=28488
--- Comment #14 from Martin Liska ---
Mark, what do you see for:
$ echo '' | as --64 -o empty.o && readelf -SW empty.o | grep note.gnu
--
You are receiving this mail because:
You are on the CC list for the bug.
https://sourceware.org/bugzilla/show_bug.cgi?id=28488
--- Comment #15 from Mark Wielaard ---
(In reply to Martin Liska from comment #14)
> what do you see for:
>
> $ echo '' | as --64 -o empty.o && readelf -SW empty.o | grep note.gnu
Nothing with GNU assembler version 2.35.2-6.fc34 since no SHT
https://sourceware.org/bugzilla/show_bug.cgi?id=28488
--- Comment #16 from Martin Liska ---
All right, one can reproduce it in fedora/rawhide container:
$ podman run --rm -it fedora:rawhide /bin/bash
$ dnf install -y elfutils gcc
$ echo 'int main() { return 0; }' | gcc -x c - -fuse-ld=gold && eu
https://sourceware.org/bugzilla/show_bug.cgi?id=28488
--- Comment #17 from Martin Liska ---
(In reply to Martin Liska from comment #16)
> All right, one can reproduce it in fedora/rawhide container:
>
> $ podman run --rm -it fedora:rawhide /bin/bash
> $ dnf install -y elfutils gcc
> $ echo 'int
https://sourceware.org/bugzilla/show_bug.cgi?id=28488
--- Comment #18 from Martin Liska ---
Note, there's BFD product:
$ eu-readelf -l a.out
Program Headers:
Type Offset VirtAddr PhysAddr FileSiz MemSiz
Flg Align
PHDR 0x40 0x00400040 0
https://sourceware.org/bugzilla/show_bug.cgi?id=28488
--- Comment #19 from Martin Liska ---
(In reply to Martin Liska from comment #18)
> Note, there's BFD product:
>
> $ eu-readelf -l a.out
> Program Headers:
> Type Offset VirtAddr PhysAddr FileSiz
> MemSiz
https://sourceware.org/bugzilla/show_bug.cgi?id=28488
--- Comment #20 from Martin Liska ---
With ld.gold one gets:
$ echo 'int main() { return 0; }' | gcc -x c - -fuse-ld=gold -o a.out
$ eu-readelf -l a.out
Program Headers:
Type Offset VirtAddr PhysAddr FileSiz
https://sourceware.org/bugzilla/show_bug.cgi?id=28488
--- Comment #21 from Mark Wielaard ---
So we have 2 bugs, one for ld.bfd:
NOTE 0x000338 0x00400338 0x00400338 0x40
0x40 R 0x8
NOTE 0x000378 0x00400378 0x00400378 0x44
0x000
https://sourceware.org/bugzilla/show_bug.cgi?id=28240
Frank Ch. Eigler changed:
What|Removed |Added
Status|NEW |RESOLVED
Resolution|---
23 matches
Mail list logo