![]() Qtopia Home - Classes - Hierachy - Annotated - Functions - Licenses - Reference |
![]() |
gdb is the GNU Debugger used to monitor program execution and to examine program status in the event of a crash.
For more information on gdb, please refer to the GNU site http://www.gnu.org/software/gdb/gdb.html
The remainder of this page provides instructions on how to debug Qtopia applications using gdb in a Linux environment.
To build an application with debug symbols:
CONFIG += debug
$ make clean $ make $ make install
To run the debugging environmnent:
$ qvfb & $ qpe & $ gdb theProgram (gdb) r # run
Alternatively to debug an application outside of the Qtopia environment:
$ qvfb & $ gdb theProgram (gdb) set args - qws # we need this to hook to the virtual frame buffer. (gdb) list # if you want to list the main.cpp file (gdb) b 6 # break at line six (gdb) r # run (gdb) s # step into (gdb) r # continue
If an application built with debug crashes, a core file is produced. Use the following commands to examine the core file contents:
$ gdb theapplication core (gdb) backtrace full
Copyright © 2005 Trolltech | Trademarks | Qtopia version 2.2.0
|