public inbox for gdb@sourceware.org
 help / color / mirror / Atom feed
* Re: Issue : external symbols aren't loaded automatically with shared objects
       [not found] <CAJiuCccd793OqxLPCq3ntm8zhV991K9wPsG4QySZJT4+Sa=ufA@mail.gmail.com>
@ 2015-02-27 18:41 ` Clément Péron
  0 siblings, 0 replies; only message in thread
From: Clément Péron @ 2015-02-27 18:41 UTC (permalink / raw)
  To: gdb

Hi,

Hope this is the good place to post my issue.

My host is a x86-64 linux computer with gdb 7.8.2
My target is a mips with gdbserver 7.8.2.

All my binaries and shared object are stripped and debug symbols are
located in a different directory.

release_dir/rootfs/usr/bin/process wich is the process i'm running on the target
release_dir/debug_symbols/process.debug the symbol file of the process

same for the shared objects
release_dir/rootfs/usr/lib/mylib.so
release_dir/debug_symbols/mylib.so.debug

After connecting gdb to the target,
i set the sysroot to release_dir/rootfs and the debug-file-directory
to release_dir/debug_symbols.

Problem gdb says that the symbols are missing :
From        To          Syms Read   Shared Object Library
0x77fdee70  0x77fe5240  Yes (*)     release_dir/rootfs/lib/ld-uClibc.so.0
0x77e97dd0  0x77fb1080  Yes (*)     release_dir/rootfs/usr/lib/libasound.so.2
0x77df82b0  0x77e5e170  Yes (*)     release_dir/rootfs/lib/libdbus-1.so.3

ObjDump of the release_dir/rootfs/usr/lib/ld-uClibc.so.0 :
Contents of section .gnu.attributes:
 0000 410f0000 00676e75 00010700 00000403  A....gnu........
Contents of section .gnu_debuglink:
 0000 6c642d75 436c6962 632e736f 2e302e64  ld-uClibc.so.0.d
 0010 65627567 00000000 d46e2530           ebug.....n%0

crc32 release_dir/debug_symbols/ld-uClibc.so.0.debug
30256ed4

The gnu_debuglink match the crc32.

https://sourceware.org/gdb/onlinedocs/gdb/Separate-Debug-Files.html as
i read it here this should automatically load the debug file matching
the crc32.

I can manually load them with the command add-symbol-file
release_dir/debug_symbols/ld-uClibc.so.0.debug 0x77fdee70

Thanks for you help :)

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2015-02-27  9:13 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <CAJiuCccd793OqxLPCq3ntm8zhV991K9wPsG4QySZJT4+Sa=ufA@mail.gmail.com>
2015-02-27 18:41 ` Issue : external symbols aren't loaded automatically with shared objects Clément Péron

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).