My preferred technique for a segfault like this is to get a core dump and open it in ddd.
First, if you don't have it:
- Code: Select all
# emerge ddd
Then you have to run a command in your console before you run SkyBox that tells it to go ahead and dump core when it aborts:
- Code: Select all
$ ulimit -c unlimited
Then run sky box, and instead of "Segmentation fault" you should get something like "Segmentation fault (core dumped)" and you should have a file named "core" in the directory you just ran from.
You can then run ddd and do File --> Open Program to open the SkyBox executable and then do File --> Open Core Dump to open the "core" file. That will essentially bring you to the point that the program was at when it failed. Go to Status --> Backtrace or simply type "bt" in the gdb console provided along the bottom of the window to get a full backtrace.
Even without nostrip you should get function names, just not the full line-number info, which probably isn't needed in this case for us to at least get a feel for what's going on.
Incidentally, collecting a core from your program is a great way to do debugging in later stages of an application when you don't necessarily want a debugger attached all the time, or when you have a non-programmer testing your code somewhere and they can produce a crash but are incapable of producing steps that allow
you to reproduce it.