This is the mail archive of the
mailing list for the binutils project.
Re: How to use dwarf-mode.el? [Was: Patch: fixlets to dwarf-mode.el]
Tom Tromey wrote:
> Georg-Johann> Is there a description how to use that mode?
> I forgot to write one.
> To start it, use M-x dwarf-browse.
> It will prompt for a file name.
> There are really only two commands available in the mode.
> If you see '...' in the buffer, that is where some DIEs have been
> omitted. You can move there and use RET to view the DIEs. With an
> argument this will show all DIEs under that point (default is just one
> more level).
> If you see a DIE reference (they are underlined and blue if you have
> font-lock), you can move there and use RET to jump to the referenced DIE.
> Georg-Johann> I tried to follow http://tromey.com/elpa/install.html with
> Georg-Johann> emacs 22 and that step appeared to pass successfully.
> Georg-Johann> dwarf-mode.el:170:1:Warning: the function `special-mode' is not known to be
> Georg-Johann> defined.
> I don't know when special-mode was added, but I guess after Emacs 22.
> You can try s/special-mode/nil/ and see if that works.
> If it does maybe I can make it adaptive.
Yes, appears to work. At least it gets me one step further until the
next problem pops up, in buffer *DWARF for mod.o*
/usr/bin/objdump: unrecognized option '--dwarf-depth=1'
Usage: /usr/bin/objdump <option(s)> <file(s)>
Display information from object <file(s)>.
At least one of the following switches must be given:
$ objdump --version
GNU objdump (GNU Binutils; openSUSE 11.1) 2.19
What I am wondering is
$ avr-objdump -d mod.o | head -n 3
mod.o: file format elf32-avr
Isn't avr-objdump the right objdump to use for that architecture?
$ avr-objdump --version
GNU objdump (GNU Binutils) 184.108.40.20620606
diff --git a/dwarf-mode.el b/dwarf-mode.el
index 4c995ef..e8ea0d1 100644
@@ -140,7 +140,7 @@ A prefix argument means expand all children."
-(define-derived-mode dwarf-mode special-mode "DWARF"
+(define-derived-mode dwarf-mode nil "DWARF"
"Major mode for browsing DWARF output.