[K42-discussion] crash in autoconf's mmap test
Bryan S Rosenburg
rosnbrg at us.ibm.com
Sat Sep 10 05:12:56 EST 2005
k42-discussion-bounces at ozlabs.org wrote on 09/08/2005 10:18:11 PM:
> Also, when I attach after the crash in GDB I get:
>
> (gdb) bt
> #0 0x00000100400a1a48 in ?? ()
>
> ... I've tried adding symbols from exec.so.dbg, libk42sys.so.1.dbg,
> and /lib64/libc.so.6 (in k42-packages), but GDB still doesn't know where
we
> are. What symbol file do I need to use here?
As you've guessed, addresses in this range are invariably in
dynamically-loaded libraries. Running the program with
LD_DEBUG=files,libs will help you determine which library. But
unfortunately that doesn't help much when the library comes from a stock
distribution (as is the case here), because it seems that those libraries
don't have symbol tables. A simple solution in this case is to link the
program statically (by, for example, adding "-static" to the gcc link
step). I found that the statically- and dynamically-linked versions fail
in the same way, and gdb on the statically-linked executable shows the
segfault to be occurring in malloc().
- Bryan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://ozlabs.org/pipermail/k42-discussion/attachments/20050909/7d0d25b1/attachment.htm
More information about the K42-discussion
mailing list