[Flightgear-devel] Re: More info on seg fault, How?

2005-02-24 Thread Melchior FRANZ
* mat churchill -- Thursday 24 February 2005 22:18:
 I'm getting seg faults 25% - 50% of the time when I try to start fg.
 This is on a fresh install of Mandrake 10.1 with the latest CVS of plib, 
 simgear, flightgear, with the latest nvidia drivers.
[...]
 it then crashes before or during the spash screen, like this.
[...]
 Is there a way to get more info from FG other than using --verbose ?


(0)  compile  link plib/sg/fgfs with 'debug' symbols (-g option)

(1)  make sure that you get core files. You may have to set ulimit -c 
unlimited
 (or some reasonable size instead of unlimited) in ~/.profilerc or 
~/.bashrc
 or elsewhere.

(2a) either wait until fgfs crashes: then load the core file into gdb (the gnu
 debugger):

$ gdb `which fgfs` core.fgfs.123456

 (whereby the core file name may look differently. The names aresettable in 
newer
 Linux kernels. This is what I use:  $ echo core.%e.%p  
/proc/sys/kernel/core_pattern

(2b) or run fgfs in gdb already:

$ gdb --args fgfs --airport-id=LFMN ...

(3)  on the gdb prompt that you get for both (2a) and (2b) you can inspect the
 code. First list a backtrace:

(gdb) bt

 after which you get a list of all stack frames, with the current one on 
top,
 from which this was called as next, etc. If you don't know what to do with
 all the info, send the backtrace to the list. I assume, though, that it's
 a local problem. Good for us. Bad for you.  ;-)

m.

___
Flightgear-devel mailing list
Flightgear-devel@flightgear.org
http://mail.flightgear.org/mailman/listinfo/flightgear-devel
2f585eeea02e2c79d7b1d8c4963bae2d


[Flightgear-devel] Re: More info on seg fault, How?

2005-02-24 Thread Melchior FRANZ
* Melchior FRANZ -- Thursday 24 February 2005 22:48:
 (0)  compile  link plib/sg/fgfs with 'debug' symbols (-g option)

adding -O0 may be useful, too. (Turns off optimization and can make the debugger
output easier to understand.)



 (2b) or run fgfs in gdb already:
 
 $ gdb --args fgfs --airport-id=LFMN ...

Here you have to start the program excution with run.

m.

___
Flightgear-devel mailing list
Flightgear-devel@flightgear.org
http://mail.flightgear.org/mailman/listinfo/flightgear-devel
2f585eeea02e2c79d7b1d8c4963bae2d


[Flightgear-devel] Re: More info on seg fault, How?

2005-02-24 Thread Melchior FRANZ
* mat churchill -- Thursday 24 February 2005 23:09:
 Is this what I should be getting ?
 
 [EMAIL PROTECTED] mat]$ gdb `which fgfs` /home/mat/core.3564
[less interesting parts]
 Loaded symbols for /usr/X11R6/lib/X11/locale/lib/common/xlcDef.so.2
 #0  0x4032fc4b in jhash_get () from /usr/lib/libopenal.so.0

Yes. But here should be a few lines more. Anyway: the crash happens in libopenal
and I recommend to download openal from their cvs and compile sg/fgfs again.

  http://www.openal.org/downloads.html

m.

___
Flightgear-devel mailing list
Flightgear-devel@flightgear.org
http://mail.flightgear.org/mailman/listinfo/flightgear-devel
2f585eeea02e2c79d7b1d8c4963bae2d