I am developing c on linux using vim and debugging using ddd. However I find that ddd performs very poorly at scrolling on this machine so its sometimes very frustrating to use.
I like the way that ddd maps fairly closely to the gdb command set as this means I am free to use gdb commands when I choose, but using gdb itself is not an option as it does not do a great job of displaying the source.
Can anybody suggest a decent alternative to ddd? I am not looking for an IDE, merely a reasonably well implemented gui facade to gdb that is free software.
What is DDD? GNU DDD is a graphical front-end for command-line debuggers such as GDB, DBX, WDB, Ladebug, JDB, XDB, the Perl debugger, the bash debugger bashdb, the GNU Make debugger remake, or the Python debugger pydb.
For C and C++ programs, gdb and ddd are debuggers that you can use. ddd is a easy-to-use GUI wrapper around an inferior debugger (gdb for GNU compiled C or C++ code). ddd allows you to interact with the debugger by using either GUI menu options or the under-lying debugger's command line interface.
To set a breakpoint in DDD, right-click on the instruction where you want to set the breakpoint, in the source window. Then, select "Set Breakpoint" from the popup menu, as shown below. The breakpoint will appear as a "stop" sign on the left of the instruction (Figure 4.2).
KDbg (http://www.kdbg.org/)
Well I tend to use either cgdb, kgdb or ddd. (and since you can't use ddd...)
cgdb is almost like the normal gdb but it shows the code in a split window above.
I use Eclipse CDT in my daily basis as well as Visual Studio and it is very good tool, as good as Visual Studio. It uses all the Eclipse infrastructure to create a very good gdb graphical interface. Is like debugging Java but with C++.
If you don't want to generate eclipse projects just for debugging because you still want to use vim as an editor you might want to know that Cmake has eclipse project generator. Some links that might help you regarding this issue: 1, 2, 3
Have you looked at the Emacs GDB integration? It's quite good, once you work out how to use it. Here's a screenshot: http://p.blog.csdn.net/images/p_blog_csdn_net/ariesjzj/pic3.jpg.
Alternatively, there's Eclipse. It's very pretty, and seems pretty comprehensive but I haven't used it much.
Failing that, I just use GDB in TUI mode (type 'layout next' lots of times until the display looks 'prettier').
I actually really miss Visual Studio now that I'm stuck developing for Linux and embedded systems.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With