Questions tagged [gud]

The GUD (Grand Unified Debugger) library provides an Emacs interface to a wide variety of symbolic debuggers. It can run the GNU Debugger (GDB), as well as DBX, SDB, XDB, Perl’s debugging mode, the Python debugger PDB, and the Java Debugger JDB.

36 questions
3
votes
2 answers

How to change GUD breakpoint keybinding to the old one

Currently, I am using GUD in the newest version of Emacs. The keybinding has changed since the old Emacs. Now it is "\C-x \C-a \C-b" for setting a breakpoint but it was \C-[space]. I was wondering if there is anyway to change the keybinding to the…
Mehrdad
  • 107
  • 8
2
votes
2 answers

lldb in emacs gud does not update source files for 'up'

I used https://opensource.apple.com/source/lldb/lldb-69/utils/emacs/gud.el and https://github.com/ptrv/emacs.d/blob/master/site-lisp/gud-lldb.el , and with emacs 24.3 and lldb in LLVM 3.9.1. It can stop at breakpoint, and display the cursor at the…
Joe C
  • 2,757
  • 2
  • 26
  • 46
2
votes
0 answers

`info args` in GDB in Emacs

Emacs' GDB integration has the Locals Buffer showing pretty much the result of (gdb) info locals. Is there way to also display the result of (gdb) info args of the current frame (without having to type it manually every time another frame is…
Johannes Gerer
  • 25,508
  • 5
  • 29
  • 35
2
votes
1 answer

emacs cancel the last action ,the ctrl+g is not very effective

Emacs usually use Ctrl+G to cancel the operation ,but when i use the GUD mode to debug a program ,the Ctrl+G is usually not working so well as i expected. For example, if i wanna to set a break point at the source test.cpp, line 223, if i input "b…
python
  • 1,870
  • 4
  • 24
  • 35
1
vote
1 answer

Can use local source files in a different directory while I use gdb over ssh in emacs?

I have a 32-bit desktop, where my copy of emacs is running. I'd like to be able to debug a program running on a very stripped down qemu 64 bit virtual machine. The virtual machine has an ssh port 24054, which gives me passwordless root access, and…
John Lawrence Aspden
  • 17,124
  • 11
  • 67
  • 110
1
vote
2 answers

How do you run multiple instance of gud in emacs

I want to debug C++ and and php in the same emacs instance (using gdb and a php debugging mode that uses gud-common-init). When I fire both up everything just gets messed up. My guess is that gud.el doesn't support this. Does anybody know if a way…
aaron
  • 1,746
  • 1
  • 13
  • 24
1
vote
0 answers

emacs save all buffers on gud debug command

I have (setq compilation-ask-about-save nil) in my init.el, so all buffers are saved before running compilation. I would like similar behavior when running gdb and pdb. Is it possible?
uuu777
  • 765
  • 4
  • 21
1
vote
2 answers

Using Emacs in PuTTY, how do I expand watched structure variable to show struct members in the gud_watch window?

In the GDB Graphical Interface for Emacs says: To expand or contract a complex data type, click Mouse-2 or press on the tag to the left of the expression. But when I press Space, the watch window do not expand to show the structure's…
whunmr
  • 2,435
  • 2
  • 22
  • 35
1
vote
1 answer

display ASCII control characters in Emacs GUD (gdb) mode

Programs I debug output a lot of debug using ascii ctrl characters for colors, bold etc. In GUD mode they appear as "^[[...m". Is there a way to have that output like it would be in a console?
chrisxxyy
  • 159
  • 1
  • 4
1
vote
1 answer

attach to a different program after detach

I used gud-gdb in emacs. First, I attached to a program1's PID 29514 (gdb) attach 29514 Attaching to program: program1 ... Then detached it. (gdb) detach Detaching from program: program1, process 29514 Then I wanted to another program program2…
Joe C
  • 2,757
  • 2
  • 26
  • 46
1
vote
0 answers

GDB in Emacs 24 messed up

I am using emacs 24.5.1 and GDB 7.10 in conjunction with the GUD integration. I am starting GUD with the following bash command: emacs --eval "(gdb \"gdb -i=mi --fullname --cd=`pwd` -args $*\")" & I have set the following variables '(gdb-show-main…
mefiX
  • 1,702
  • 3
  • 24
  • 39
1
vote
2 answers

gdb within emacs: python commands (py and pi)

I want to debug a c++ program using gdb. I use the pi and the py commands to evaluate python commands from within gdb, which works fine when I invoke gdb from the command line. However, when I invoke gdb from within emacs using M-x gdb and then gdb…
user280107
  • 11
  • 1
1
vote
2 answers

How to customize the executable name when running gud-gdb

I am using emacs 24.3.1 to write programs (in C and C++ mode). After compiling the current buffer, I run below command: M-x gud-gdb. Emacs gives a prompt like below: gdb --fullname prog However, sometimes the "prog" name is not the same as the…
modeller
  • 3,770
  • 3
  • 25
  • 49
1
vote
2 answers

Programmatically Setting Emacs Window as Input Focus

How do I programmaticaly force my Emacs X Window to get current user input focus? I want to use this in the following Bash script # Debug in Emacs using GDB function emacs-gdb() { if [ -z $1 ]; then echo -e "Usage: $FUNCNAME EXE…
Nordlöw
  • 11,838
  • 10
  • 52
  • 99
1
vote
1 answer

Equivalent of Visual Studio's Watch Window in GUD

I am using Emacs 23 to do some C development, with GUD (using GDB) as my debugger. I have looked online, but haven't yet found an equivalent to Visual Studio's Watch Window in GUD. Essentially, this window lets you insert a list of expressions,…
Daniel Neel
  • 1,197
  • 13
  • 28