Re: pthreads debug with gdbserver

Daniel Jacobowitz
2004-11-19T14:23:04Z

On Fri, Nov 19, 2004 at 12:33:22PM +0200, Vladimir Vorobyov wrote:
> I see that shlib breakpoint is set and hit but gdb does not load the
> libraries. I can see in strace that it successfully loads ld.so. What should
> I look at?

"info shared". Maybe strace GDB to see what it's opening and whether
it fails to find any files.

> Next, what libthread_db.so is for? It was not included for compilation for
> m68k target and I added it manually but when I try to load all libraries
> manually using add-symbol-file, every library loads fine except
> libthread_db.so - gdbserver reports "gbd: error initializing thread_db
> library."
> If I type in gdb:
> info threads
> I always get only one thread.
> p.s. All libraries are not stripped.

libthread_db.so is necessary to debug threads. It has to be on your
target (sounds like it is) and it has to be able to initialize; worry
about this after you've figured out whether GDB loaded shared
libraries, because it will not be able to initialize unless GDB can
load an unstripped copy of libpthread.so.

--
Daniel Jacobowitz