You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Under Gentoo distribution (Linux), if a library is built with splitdebug feature where debug symbols are splited from the elf binaries into one specific location under /usr/lib/debug directory. However, somehow the tool used to split debug symbols only creates debuglink without introducing build-id. It is different from Debian-style and Fedora-style. Could we add support loading symbols from debuglink?
Both of gdb and lldb can load symbols from debuglink without extra setups.
(gdb) b main
Breakpoint 1 at 0xd81d7: file /home/hky/yass/src/cli/cli.cpp, line 37.
(gdb) r
Starting program: /home/hky/yass/build-release/yass_cli
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".
Breakpoint 1, main (argc=1, argv=0x7fffffffd948) at /home/hky/yass/src/cli/cli.cpp:37
37 if (!SetUTF8Locale()) {
(gdb) info shared
From To Syms Read Shared Object Library
0x00007ffff7fcb060 0x00007ffff7ff00c1 Yes /lib64/ld-linux-x86-64.so.2
0x00007ffff7ee11f0 0x00007ffff7f4fb69 Yes /lib64/libm.so.6
0x00007ffff7eb7330 0x00007ffff7ecccdd Yes /usr/lib/gcc/x86_64-pc-linux-gnu/12/libgcc_s.so.1
0x00007ffff7d03380 0x00007ffff7e52bc9 Yes /lib64/libc.so.6
Split debug files are located at /usr/lib/debug directory (at least, gentoo).
Could not load debug symbols for "/lib64/libc.so.6": Failed to find symbols for module "/lib64/libc.so.6" with build_id="":
- Unable to find local symbols for module "/lib64/libc.so.6": build id is empty.
- Not able to search for symbols on the instance.
Also: Could not load fallback symbols for "/lib64/libc.so.6":
* Could not find module file itself in cache: Unable to find object file in cache for module "/lib64/libc.so.6"
* Could not find module file itself locally.
* Could not search for module file itself on the instance.
Using readelf tool, it shows there is no build-id section:
➜ build-release git:(develop) readelf -n /lib64/libc.so.6
Displaying notes found in: .note.gnu.property
Owner Data size Description
GNU 0x00000020 NT_GNU_PROPERTY_TYPE_0
Properties: x86 feature used: x86, x87, XMM, YMM, ZMM, MASK
x86 ISA used: x86-64-baseline, x86-64-v2, x86-64-v3, x86-64-v4
Displaying notes found in: .note.ABI-tag
Owner Data size Description
GNU 0x00000010 NT_GNU_ABI_TAG (ABI version tag)
OS: Linux, ABI: 3.2.0
Chilledheart
changed the title
Support split debug symbols without debug-id (gentoo-style)
Support split debug symbols without build-id (gentoo-style)
Jun 20, 2023
Under Gentoo distribution (Linux), if a library is built with
splitdebug
feature where debug symbols are splited from the elf binaries into one specific location under/usr/lib/debug
directory. However, somehow the tool used to split debug symbols only creates debuglink without introducing build-id. It is different from Debian-style and Fedora-style. Could we add support loading symbols from debuglink?Both of gdb and lldb can load symbols from debuglink without extra setups.
Split debug files are located at
/usr/lib/debug
directory (at least, gentoo).Using
llvm-readobj
to dump debuglink section:The text was updated successfully, but these errors were encountered: