Collection of scripts to use gdb as source level debugger for SmallEiffel.

--- Contents
(1) Emacs code
 edb-emacs.el	        emacs(>=19) interface gdb for debugging SmallEiffel.
 edb-xemacs.el		xemacs(>=21)interface of gdb for debugging SmallEiffel.
 gud.patch.el           gud.el patch to fix bug in gdb.el
 gud-edb.el             edb interface (almost the same as gdb interface of gud)

(2) Perl script
 sec	SmallEiffel compiler driver and patch script
	It converts C codes  generated by SmallEiffel to use gdb.
        (1) Change in-line debugging information to the line directives
            #line ...
        (2) Rename local variables.
	(3) Remove debugging code and extra arguments.

-- Requirement
  SmallEiffel -0.77 or later
  xemacs (>=21) or emacs(>=19)
  gdb    (>=4.17)
  perl   (>= 5)

-- How to install
1. Place edb-emacs.el or edb-xemacs.el under the emacs load-path directory.
   Byte compiled code will not run under xemacs because of gud bug.
   Insert autoload command into your .emacs

   (autoload 'edb "edb-emasc" nil t)  ;;  for emacs
   (autoload 'edb "edb-xemasc" nil t) ;;  for xemacs

2. Place `sec' on your private PATH directory. chmod +x them.
   These scripts assumes perl is installed at /usr/local/bin.
   If the location is different, rewrite header comment of these scripts.

3. Symbolic link gdb to edb.

4. If you want to use Boehm's gc library, uncomment the line
   `#$gc = "c";' in the `sec' script.
   The gc library is assumed to be installed under /usr/local.

-- How to use.
1. compile
 % sec target root [option ..]
    target : target program name
    root   : root class name
    option : assertion level -debug ~ -boost, -opt
             -c c-source-file
 (Caution.  root creation procedure must be `make'.)

2. Debug
 Almost the same as gdb (command name is edb)

 * set break point on eiffel source.
 * print local variale of eiffel.
 * print object attributes in effel syntax like

 (gdb) p object.attribute1.atribute2 
  $3 = {id = 57, _attr1 = 27, attr2 = 0x100c1000}
 (gdb) p $3.attr2
  $5 = {id = 64, _x = 5, _y = 7}

--------------

Masato Mogaki mmogaki@kanagawa.hitachi.co.jp
DA Development Dept.
E.S.D. Hitachi,Ltd.

