Questions tagged [gud]

Grand Unified Debugger

Filter by
Sorted by
Tagged with
8
votes
2answers
1k views

How can I prevent gdb *input/output* buffer from aggressively popping up in frame?

When using gdb with M-x gdb, the *input/output* buffer always pops up aggressively in any frame which has focus and isn't already displaying it. I would like the *input/output* buffer to stay quietly ...
6
votes
1answer
2k views

How do I change the working directory used by pdb/gud?

When running M-x pdb from Emacs, the current directory seems to be set to that of the directory of the script you are running, so pdb ~/path/to/project/__main__.py Would set the working directory ...
6
votes
0answers
847 views

gud: highlight breakpoints with custom debugger

I use go-dlv to debug Go programs. This package is very simple and relies on standard gud functionality (https://github.com/benma/go-dlv.el/blob/master/go-dlv.el) One thing that I found missing is ...
5
votes
2answers
1k views

How to set gud gdb -i=mi not to replace current buffer?

When using gdb -i=mi to debug a program, I typically split the window into two buffers vertically. But every time my program prints something gud automatically replaces my source code buffer with I/O ...
5
votes
0answers
201 views

How to map file paths when using docker

I'm running code in development using docker. I do that using the -v flag to docker run to mount my code in the container. I've set directory-abbrev-alist and configured compilation-error-regexp-...
4
votes
1answer
2k views

Customizing the layout of gdb-many-windows

I really like all of the information that is available to me when I run GUD/GDB with gdb-many-windows, but I would like to be able to move the windows around some. Specifically I would like to use ...
4
votes
0answers
251 views

Is it possible to debug Django from gud-pdb?

Brand new to gud/pdb and I am trying to run the Django development server from emacs. I can't seem to set breakpoints that affect the running server, though. I am invoking PDB with M-x pdb, then ...
3
votes
3answers
3k views

How do you break a running program under gud?

In the vanilla gdb interface, I can hit C-c to break the running program, insert breakpoints, etc., and then run continue to resume execution of the program being debugged. Is this possible with gud? ...
3
votes
1answer
999 views

highlight breakpoints with pdb

I use pdb with gud to debug python scripts. I am just wondering if there is way to highlight the lines with breakpoints? For example, in some screenshots of gud-gdb, some people seem to have red ...
3
votes
0answers
516 views

Debugging in Unity3d with emacs?

I develop in Unity, and have been using emacs as my text editor for development. Debugging however has always needed to be done through monodevelop (and it crashes half the time while doing this). My ...
2
votes
1answer
493 views

Show breakpoints when debugging Matlab

I am using matlab-emacs to debug a matlab script from inside of emacs with GUD. Everything seems to be working as expected except that I don't see any breakpoint indicators in the fringe. This is ...
2
votes
2answers
174 views

Highlight current line in GUD disassembler window

I am using GUD for debugging C code. Because many of the lines and variables have been optimized away, it is necessary to follow the C source and the corresponding disassembly simultaneously. I want ...
2
votes
1answer
628 views

How can I delete all the gdb related windows/buffers after `q` in gdb CLI window

I use (setq gdb-many-windows t) and (setq gdb-show-main t) configurations in my init.el, so after executing M-x gdb, there will be six windows in the frame, after typing q in the main gdb cli window ...
2
votes
1answer
346 views

gdb-many-windows causes hangs in emacs 24.5

When running gdb -i=miand then attach to the process for debugging, emacs hangs for like 5 minutes before I can type anything. After trial and error I found it is caused by the following line in my ...
2
votes
1answer
339 views

Is gud working at all in emacs 24?

I am trying to switch from vim to evil mode and got very far. The last thing what is missing is debugging with "gdb". I want to be equally productive as with clewn in vim (this means source level ...
2
votes
1answer
329 views

Make comint-mode behave more like term-mode

I am constantly getting frustrated with the GDB comint-mode buffer when using GUD. Somehow my cursor always ends up straying from the bottom of the buffer, and then my input is not interpreted how I ...
1
vote
1answer
1k views

How to browse through the gdb command history in gud?

From time to time I am using gdb through the gud Emacs interface to debug my C programs. Nevertheless, I find extremely annoying to not be able to browse the gdb command history by just using the Up ...
1
vote
2answers
926 views

gud opening source in gud interaction window

When debugging with gud and gdb in many-windows mode, some source files are opened in the gud interaction window instead of the source window. This appears to happen to files, and only those files, ...
1
vote
1answer
120 views

Problem debugging in `gud-mode' (M-x `gdb' with `many-windows' enabled)

I'm debugging a large codebase (written in C++). Everything works perfectly if I run gdb from a regular terminal as follows: $ gdb <program-name> Reading symbols from <program-name>......
1
vote
1answer
248 views

Can't start gdb over ssh

I am able to open a remote C source file using tramp (via ssh). However, when I try to debug it using M-x gdb gdb -i=mi /ssh:localhost#8022:/usr/bin/httrack I get Current directory is /ssh:...
1
vote
1answer
359 views

Bindings for source code when debugging in gdb/gud

We can define a bunch of bindings for gud-mode through gud-mode-map. But it seems these bindings only hold when the active window is one of the dedicated gdb windows (or simply the comint window if ...
1
vote
0answers
54 views

Show the current command line the frame title in a GDB session

I sometimes run multiple instances of Emacs, each running a GDB session. These GDB sessions are often running different versions of the same program, or the same program with different arguments, so I'...
1
vote
0answers
262 views

How I can show the breakpoints dots per-line on file-buffer using gud-gdb?

Using gdb defined by package gdb-mi.el I got the breakpoints red dots after click on line with mouse or defining on gdb buffer. However, using a alternative wrapper for gdb present on the stantard ...
1
vote
1answer
227 views

Conditional Keybinding for gdb: gud-step if debugging, otherwise gud-run

I have been trying around getting one keybinding <F7> to perform one gud-step command if a debugging process is running. If it is not running it shall perform gud-run. I am not very familiar ...
1
vote
0answers
224 views

Enabling compilation-shell-minor-mode in GUD (for next-error)

I want to see stack trace lines highlighted in GUD and have next-error work there. That works for me if, after starting GUD (via M-x pdb) I enable compilation-shell-minor-mode. However, if I do this:...
1
vote
0answers
76 views

Jumping from gud-interaction-buffer to code

I'm trying to use GUD more as a front-end to GDB. I mostly work in the interaction buffer as I do normally on the command line. However when I come across a particular line in the code (through bt or ...
1
vote
0answers
220 views

emacs gdb *gud* “window” undisplayed/deleted after command

(Manually moved by copy/pasting from this Unix SE deleted question) I'm debugging my MELT monitor, in relation with MELT (a domain specific language & meta-plugin to extend & customize the ...
0
votes
1answer
37 views

Set colour/font for markers [duplicate]

Is it possible to set the colour or font of markers (e.g. the ones set by gud in gud-display-line by using make-marker). The theme I am using shows markers in a difficult-to-see light gray. I would ...
0
votes
1answer
336 views

How to step into a c++ std library function in gdb/gud

This is most likely an issue with g++/gdb/other, but an indirect issue within Emacs nonetheless. Whilst debugging, I would like for Emacs to step into the standard library implementation of the ...
0
votes
1answer
256 views

gud-break doesn't work with jdb

I successfully attach to my java app with emacs & gud, but gud-break doesn't work as expected: it runs only: stop at :48 if the line number is 48. So even the class name is missing and the ...
0
votes
1answer
177 views

GUD mode: check if program is running

I'd like to use one hotkey for continuing running (gud-cont) and starting running (gud-run). How can I check if gdb (or other debugger, if possible) is running a program right now? Is there a debugger-...
0
votes
0answers
17 views

monitor commands from gud/gdb command line not showing output

In a plain terminal, I can run gdb, connect to gdb server via 'target remote :nnnn` and then use the 'monitor' command to send commands to the remote app, and the results from running those commands ...
0
votes
0answers
40 views

pdb hangs through gud on emacs when path has `@` symbol

more tests I've now confirmed this behavior in Emacs 24.5 on a linux machine. Basically, if there is an @ symbol in one of the parent directories, gud will hang. the first update I've actually ...
0
votes
0answers
28 views

emacs c++ gud cannot skip non existing file, making it unusable

I have this file: #include <string> using namespace std; string remove(string s) { return s; } int main() { string s1 = "aaaa"; string s2 = remove(s1); return 0; } g++9 ...
0
votes
0answers
59 views

Gdb: run a hook when the program is being started

I'm using M-x gdb to debug a program that produces some output. The output appears in the buffer *input/output of a.out*. I often run the same program multiple times during a session, often after ...
0
votes
1answer
3k views

GUD debugger says: Undefined command: “-interpreter-exec”

I am following the tutorial Open GDB (within Emacs for added functionality) on Emacs 25.2.1 with Evil Spacemacs and Ivy (the commands gud-gdb and gdb get the same results): SPC f f (counsel-find-file)...
0
votes
1answer
119 views

After `M-x pdb` switch to `compilation-mode` automatically?

M-x pdb is great while debugging. When the python process exits though, often there is a traceback left behind in the gud buffer that I'd like to view using compilation-mode so I can use next-error ...