cross debug glibc loader problem

Matt Rice ratmice@gmail.com
Wed Feb 10 19:45:00 GMT 2010


On Wed, Feb 10, 2010 at 4:09 AM, Amker.Cheng <amker.cheng@gmail.com> wrote:
> Hi all:
>  I am trying to debug glibc loader, e.g. ld.so.
> I am following instructions at
> http://sources.redhat.com/glibc/wiki/Debugging/Loader_Debugging,
> the only difference is the cross debugging by running gdbserver from a
> mips simulator.
> the start up command is :
> ------------------------------
> EGLIBC=/home/user/working-dir/eglibc-test/build/glibc
> mipsel-linux-gnu-gdbserver --debug 192.168.10.2:3333 \
> $EGLIBC/elf/ld.so.1
> "--library-path
> $EGLIBC:\
> $EGLIBC/math:\
> $EGLIBC/elf:\
> $EGLIBC/dlfcn:\
> $EGLIBC/nss:\
> $EGLIBC/nis:\
> $EGLIBC/rt:\
> $EGLIBC/resolv:\
> $EGLIBC/crypt:\
> $EGLIBC/nptl \
> $EGLIBC/string/tester
>
> then I trying to connect gdbserver in gdb command line by :
>
> target remote 192.168.10.2:3333
>
> strangely, gdb complains that it :"Cannot access memory at address 0x32a14".
>
> I have totally no idea about this question, so please help and any
> tips will be appreciated.
>
> Thanks very much.
>
> the remote log file is attached, hoping helpful:

I would try it out with gdb from cvs, and if that doesn't work
investigate Jan Kratochvil's recent PIE: series of threads on the
gdb-patches list (at least some of which have been integrated), as I
am lead to believe from the first thread in the series that those
patches covered debugging ld.so.



More information about the Gdb mailing list