[maemo-developers] Help debugging segfaults

From: Simon Pickering S.G.Pickering at bath.ac.uk
Date: Tue Feb 27 12:14:27 EET 2007
<snip lots of gdb output>

> To get working backtrace on ARM you need to have either:
> - debug symbols, or
> - code compiled with -fno-omit-frame-pointer for *every* 
> binary/library you see in the backtrace, otherwise Gdb 
> reports bogus information for the backtrace.  In this case 
> the libs would be:
> - /usr/lib/libstdc++.so.6
> - /usr/lib/libgiac.so.0
> - /lib/ld-linux.so.3 (I think this is wrong, but in general you
>    almost always need at least minimal debug syms on C-library)
> The reason is that without either debug symbols or 
> framepointer Gdb doesn't know how many args to skip when 
> unwinding the stack. Even the first function it shows is 
> often wrong, because without debug symbols Gdb can try to 
> match it only to the nearest _exported_ function and the 
> function might have been a static (non-exported) one.

Thanks for the explanation. I did compile the icas binary with -g and
-fno-omit-frame-pointer (and it's unstripped), so presumably this means that gdb
should know which function in the icas binary has called the failed chain of

Strange that icas is never mentioned, or perhaps it's just because the function
chain is too long? I'll try compiling libgiac with -g and
-fno-omit-frame-pointer (I don't think I really want to try re-compiling gcc
atm) and see whether I can narrow the error down.



More information about the maemo-developers mailing list