简体   繁体   English

如何使GDB与外部程序一起使用

[英]How to make GDB work with external programs

I am very interested in learning more about the specifics of debugging, and I am looking into making a very simple GUI for debugging with GDB. 我对了解有关调试细节的更多信息非常感兴趣,并且正在寻求制作一个非常简单的GUI来进行GDB调试。

I understand in general how debuggers work, but I am having trouble of how an IDE interacts with an external debugger like GDB. 我大致了解调试器的工作原理,但是我很难理解IDE如何与外部调试器(如GDB)进行交互。

I am sure I could call commands to setup breakpoints and such in the debugger, but I am unsure of how an IDE would get the information back like, oh the breakpoint you set has been hit or variable values and such. 我确定我可以在调试器中调用设置断点的命令,但是我不确定IDE如何获取信息,例如,设置的断点被命中或变量值等等。 Is there good information of using GDB within another program, I tried searching google, but all results I get are about how to debug another program using GDB or setting it up in a IDE already developed. 是否有在其他程序中使用GDB的良好信息,我尝试搜索google,但获得的所有结果均与如何使用GDB调试另一个程序或在已开发的IDE中进行设置有关。

does it involve hooking into GDB? 是否涉及钩接到GDB? or does GDB have a library? 还是GDB有图书馆?

Thanks. 谢谢。

does it involve hooking into GDB? 是否涉及钩接到GDB? or does GDB have a library? 还是GDB有图书馆?

No and no. 不,不。

GDB has a machine interface , intended for interfacing between and IDE and GDB. GDB有一个机器接口 ,用于在IDE和GDB之间进行接口。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM