When the terminal says login, type your netid and press Enter. When it says password, type your password and press Enter. You'll see a few messages and then a > prompt. The terminal is now talking to an ``icarus shell.''
If you make a mistake typing a command for the shell, type ^C (hold down Ctrl, type C, release Ctrl) to cancel the command.
Type exit (and press Enter) when you're done.
Click on Start, then Programs, then Network, then Exceed, then Exceed again. A window will appear listing names of machines. Click on icarus. An icarus login window will appear. Enter your netid and password. The login window will disappear, and be replaced by various windows for other programs. This process may take a minute; relax and read your textbook.
If you want to start a terminal inside Exceed after you've logged in, find the Terminal application and click on it.
If you're using a terminal inside Exceed, you can type /homes/home12/koobera/bin/ups fun instead of gdb fun. ups is another debugger, with several advantages over gdb.
Typical debugger commands:
|See the program.||list||It's already on the screen.|
|Set a ``breakpoint.''||break 7 for a breakpoint at the beginning of line 7.||Right-click on the line.|
|Run the program. Pause the program if it reaches a breakpoint.||run||Click Start.|
|While the program is paused, show the value of variable x.||print x, or display x to show x after subsequent breakpoints.||Click x. Or double-click main under Functions to see all variables inside main.|
|Continue running the program.||cont||Click Cont.|
|Continue running the program, but pause at the next line.||next||Click Next.|
|Quit the debugger.||quit||Click Quit.|
ups shows only the first element of an array by default. The easiest way to see the remaining elements is to click on the first element, then click Dup as many times as the array has elements.
See http://www.concerto.demon.co.uk/UPS/upsman.html for more information on ups.
#!/bin/sh gcc -Wall -g -o $1 $1.c && /homes/home12/koobera/bin/ups $1and then type chmod u+x debug. The file debug is now a ``shell script.'' Typing ./debug 3 has the same effect as typing
gcc -Wall -g -o 3 3.c && /homes/home12/koobera/bin/ups 3