Node: Using gdb, Next: , Up: gdb Tutorial



Using gdb

Gdb comes with extensive online documentation. Much of the doucmentation is available within gdb itself through the help command. J2c defines a couple useful commands that are documented through help. help user-defined will list them, and help cmd will display help for a particular command. While gdb's built-in help can be useful, the reference manual contains more complete documentation, including a breif tutorial. The location and format of the reference manual varies between platforms.

On Macs, gdb's online reference manual is available through <file://localhost/Developer/Documentation/DeveloperTools/gdb/gdb/gdb_toc.html>. The gdb source distribution also includes a double-sided quick reference card, which Apple has been thoughtful enough to package as a .pdf in /Developer/Documentation/DeveloperTools/gdb/refcard.pdf.

Gdb's online reference manual is available on linux boxes through emacs and the standalone info command. In emacs, type <ctrl>-h i, search for gdb, and follow the link by either middle-clicking on the bold text, or hitting return while the cursor is on bold text. Redhat does not seem to install the quick reference card anywhere, but the Apple version is available at /p/sss/project/apple-gdb-refcard.pdf.