Article View: gnu.gdb.bug
Article #10059man page
From: Warren Jasper
Date: Tue, 26 Jun 1990 21:48
Date: Tue, 26 Jun 1990 21:48
188 lines
5352 bytes
5352 bytes
Since FSF is coming out with a version of troff, I decided to make a man page for gdb. Enjoy, -- Warren ----------------------------- Cut Here ------------------------------ .TH GDB 1L "23 June 1990" "GNU" "LOCAL USER COMMANDS" .SH NAME gdb \- GNU source level debugger .SH SYNOPSIS .B "gdb " [ .B \-nx ] [ .B \-q ] [ .B \-batch ] [ .B \-fullname ] [ .I file-specifying option ] [ .I program [ .I corefile ] ] .SH WARNING This man page is an extract of the documentation of .I GNU GDB. It is updated only occasionally, because the GNU project does not use nroff. For complete, current documentation, refer to the Info file .B gdb or the DVI file .B gdb.dvi which are made from the Texinfo source file .BR make.texinfo . .SH DESCRIPTION .IX gdb "" "\fLgdb\fP \(em source debugger" .IX "debug tools" "gdb command" "" "\fLgdb\fP \(em source debugger" .IX "programming tools" "gdb debugger" "" "\fLgdb\fP \(em source debugger" .LP The purpose of a debugger such as .B gdb is to allow one to execute another program while examining what goes on inside it. The other program is called "the program being debugged". .B gdb can be used to debug programs written in C and C++. Pascal support is being implemented, and Fortran support will be added when the GNU Fortran compiler is written. .LP .B gdb is invoked with the shell command .B `gdb'. Once started, it reads commands from the terminal. A .B gdb command is a single line of input. There is no limit on how long it can be. It starts with a command name, which is followed by arguments whose meaning depends on the command name. Type ``help'' for a list of commands. .LP .I program is an executable file, produced by .BR cc (1V), .BR gcc (1L) or another compiler, with the .B \-g option to include a symbol table. This symbol table contains the names of all the source files used to create it, and these files are available for perusal while using the debugger. .LP If no .I program is specified, you can use .BR gdb 's .B exec-file command to specify the program to debug. .LP If there is a file named .B core in the current directory, or a .I corefile argument is specified, you can use .BR gdb to examine the state of the program when the core file was produced. .LP When .B gdb starts, it automatically executes its .I init files, which are command files named .B .\|gdbinit. .B gdb reads the init file (if any) in the user's home directory and then reads the init file (if any) in the current working directory. .LP .SH OPTIONS .sp 1 .TP 0.65i .B \-nx Do not execute commands from the init files .B .\|gdbinit. Normally, the commands in these files are executed after all the command options and arguments have been processed. .TP 0.65i .B \-q ``Quiet''. Do not print the usual introductory messages. .TP 0.65i .B \-batch Run in batch mode. Exit with code 0 after processing all the command files specified with .B \-x (and .B .\|gdbinit, if not inhibited). Exit with nonzero status if an error occurs in executing the .B gdb commands in the commands files. .TP 0.65i .B \-fullname This option is used when Emacs runs .B gdb as a subprocess. It tells .B gdb to output the full file name and line number in a standard, recognizable fashion each time a stack frame is displayed (which includes each time the program stops). This recognizable format looks like two `\\032' characters, followed by the file name, line number and character position separated by colons, and a newline. The Emacs-to-GDB interface program uses the two `\\032' characters as a signal to display the source code for the frame. .SH File-specifying Options All the options and command line arguments given are processed in sequential order. The order makes a difference when the .B \-x option is used. .sp 1 .TP 0.65i .BI "\-s " file Read symbol table form file .I file. .TP 0.65i .BI "\-e " file Use file .I file as the executable file to execute when appropriate, and for examining pure data in conjunction with a core dump. .TP 0.65i .BI "\-se " file Read symbol table form file .I file and use it as the executable file. .TP 0.65i .BI "\-c " file Use file .I file as a core dump to examine. .TP 0.65i .BI "\-x " file Execute .B gdb commands from file .I file. .TP 0.65i .BI "\-d " dir Add .I dir to the list of directories in which to search for source files. .SH "SEE ALSO" .PD 0 .TP 2.0i /usr/local/doc/gdb.dvi .I GDB Manual, The GNU Source-Level Debugger .PD .SH AUTHOR This manual page contributed by Warren J. Jasper of Stanford University. The GDB Manual is written by Richard M. Stallman.
Technical Details
Message-ID:
<9006262248.AA14282@aspen.Stanford.EDU>Path:
arc1-ca.pugleaf.net!gmdzi!unido!mcsun!uunet!tut.cis.ohio-state.edu!SUN-VALLEY.STANFORD.EDU!wjjShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: f5053,ab24cd9a6dbf39ff,start X-Google-Attributes: gidf5053,public X-Google-ArrivalTime: 1990-06-26 18:15:05 PST Path: arc1-ca.pugleaf.net!gmdzi!unido!mcsun!uunet!tut.cis.ohio-state.edu!SUN-VALLEY.STANFORD.EDU!wjj From: wjj@SUN-VALLEY.STANFORD.EDU (Warren Jasper) Newsgroups: gnu.gdb.bug Subject: man page Message-ID: <9006262248.AA14282@aspen.Stanford.EDU> Date: 26 Jun 90 21:48:22 GMT Sender: daemon@tut.cis.ohio-state.edu Reply-To: wjj@sun-valley.stanford.edu Distribution: gnu Organization: GNUs Not Usenet Lines: 188 Posted: Tue Jun 26 22:48:22 1990