Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

gud-gdb emacs 24 not working

Tags:

emacs

gdb

emacs24

I'm having difficulties with gdb under emacs 24. I compiled my c code with the -g switch, and the symbol table loads in gdb. The problem I'm having is that no source code is shown when I load my application, no breakpoints are visible. I guess there appears to be no connection between the source code buffer and gdb buffer.

I have used gdb under emacs before (emacs 22, and 23) and it worked well and now it doesn't. I also tried it under emacs -q so no plugins are loaded in case my .emacs was at fault, no joy.

Just to recap (so I don't get "compile with -g" answers):

  • I compiled with -g I loaded emacs with no plugins
  • I used annotate=3with gud-gdb
  • I even tried gdb-mi (doesn't work at all, didn't pursue this road any further)

Gdb ain't working with source code showing (with breakpoints). What can I do to fix it, or at least how can I find out what's wrong?

like image 504
bing Avatar asked Mar 12 '12 23:03

bing


1 Answers

M-x gud-gdb is not for use with annotate=3 but with --fullname (aka --annotate=1, IIRC).

like image 153
Stefan Avatar answered Sep 21 '22 12:09

Stefan