From OC Systems Wiki!
adbg - run the debugger
adbg [-h] [-L Library] [-r UID@Host] [-x Program [-c corefile] ] [-FR][-mono|-gray][-f FileName][-a PID]
Invoke the debugger with the adbg command.
- Displays a help message for the debugger.
- Specifies that the X windows display is grayscale rather than color.
- Specifies that the X window display is monochrome rather than color.
- Specifies that the debugger should not check for consistency between the Ada Library and the executable Program. Specify this if you wish to ignore inconsistencies, or if you know they are consistent and wish to reduce the debugger's startup time.
- -L Library
- Specifies the name of the library list file to use instead of the library stored in the Program file. If specified, the debugger reads this file to determine which sublibraries hold the compilation units you are debugging.
- -r UID@Host
- Uses user id UID on remote host Host.
- -x Program
- Specifies the path name of the executable file to be debugged. The program's main unit name and (if
-Lis not specified) the library as well are extracted from the Program file. If this option is not specified, the local file a.out is assumed. For example, if the executable file name is sorter_version2 and the file is located in the directory /usr/smith/tools, you might run the debugger using the command:adbg -x /usr/smith/tools/sorter_version2
- -c corefile
- Allows the user to specify a core file to be read by the debugger. Note that the -x parameter is necessary to use a core file.
- Specifies files to use as standard input and standard output for the target program when it is run inside the debugger under AIX or Linux windows; it does not work in the curses environment. When you use this option, you must invoke the debugger with I/O redirection or as part of a pipeline. For example: adbg -R CompilationUnit >ToFile <FromFile specifies that the program being debugged takes its input from FromFile and puts its output to ToFile.
- -f FileName
- Specifies the start-up file to be used in addition to the default
- .adbgrc file. For example
- adbg -f script_one
- causes the debugger to execute the commands in .adbgrc and then the commands in script_one when it starts up. You can use this option to provide a different debugging environment, perhaps with a different set of debugger variables and macros, or to automate the debugging process by running an entire session as a script.
- -a PID
- Attaches to a running process, where PID is the process ID of the process.
The debugger commands are:
.BREAK .CALLS .DISASSEMBLE .MOVE .READ .REGISTERS .SKIP .STEP .SYMBOL .TRAP .UNBREAK .UNTRAP .WRITE := ? BEGIN BOTTOM BREAK CALLS CLEAR CLOSE CONTINUE DECLARE DEFAULT DETACH DOWN EDIT END EXIT GET_LINE HELP HISTORY IF IMPORT IN INVOKE LOAD LOG LOOP MACRO MODE NULL OPEN PUT_LINE RESIZE SCRIPT SHOW SKIP STEP SOURCE SYSTEM TASKS TRACK TRAP UNBREAK UNDECLARE UNTRACK UNTRAP UP WHERE WHILE
- the debugger startup program
- the debugger program image
$POWERADA/tools/bin/Adbggui - the debugger GUI program image $POWERADA/adarte/bin/Adbgagent the debugger remote agent program image $POWERADA/tools/bin/adbg.hlp the non-Motif debugger on-line help file $POWERADA/tools/bin/adbg.ksh wrapper script for adbg $POWERADA/tools/lib/app-defaults/Adbg X resources file for the debugger GUI
- used to locate the display device for the debugger GUI to use. It must be defined to an existing display, generally "hostname:0". If DISPLAY is not set, the debugger will try to open a Curses window on the current display device. If that fails, the debugger will run in dumb terminal mode.
- This must be defined and indicate the powerada/ada95 directory in the PowerAda installation.
- Names a baselines file identifying aliases for baseline projects.
- indicates the location of the PowerAda installation on the remote, target machine, if different than POWERADA on the host. If defined, the file Adbgagent must be in $POWERADA_REMOTE/adarte/bin. Note that all references to target-related files and programs should include full path specifications because the remote agent does not execute in a user login environment.
- starts the debugger to debug the program in
a.outusing the main unit and the library stored in
adbg -L deblib.list
- starts the debugger using the library
deblib.listto debug the program in
adbg -x test.exe -a 12345
- starts the debugger to debug the program running in the process whose pid is 12345 whose executable file is
adbg -x test.exe -a 12345 -r fred@thor
- starts the debugger to debug the program running under the user id of
fredon the host named
thorin the process whose pid is 12345 whose executable file is
test.exe. The debugger will prompt for the password of user id
thoras follows:Password for fred@thor: