C / C ++ Linux GDB API

I want to make a small version of the GDB graphical command-line program on Linux to make it easier to debug small C programs. There are already some features in the IDE, but I want to do it for fun and get a better known GDB value.

Now I wanted to know if the GDB API had it so that I could directly access the GDB commands from the code, and I did not need to do a crawl through the terminal, for example, using popen .

If such an API does not exist from GDB , then what is the easiest way to start hidden GDBs and send commands to it, extract exits from it?

+8
c ++ c linux gdb
source share
1 answer

Many IDEs, such as Eclipse and KDevelop, use GDB MI (machine interface). This is a linear oriented text interface for GDB. See the full list here: https://sourceware.org/gdb/wiki/GDB%20Front%20Ends .

Check out these links to get started with GDB MI:

+2
source share

All Articles