在Windows上无法在Qt Creator中选择GDB [英] Can't select GDB in Qt Creator on Windows
问题描述
我在Windows上选择了GDB而不是CDB作为Qt Creator中的调试器:
I've selected GDB instead of CDB as the debugger in Qt Creator on Windows:
但是当我开始调试程序时,它会失败并显示此错误:
But when I start debugging a program, it fails with this error:
Unable to create a debugger engine of the type "No engine"
如果我选择CDB组合。为什么我得到这个错误,如何解决它?
It works if I select CDB from the Combo. Why am I getting this error, and how do I fix it? I assume I do have GDB installed if it's in the combo box, right?
编辑:我看到问题可能在哪里,但仍然不知道如何解决它:
I see where the problem might lie, but still no idea how do I fix it:
[在新标签页中打开上面的图片以全分辨率查看。]对于GDB,显示无法识别。
[Open the above image in a new tab to see in full resolution.] It says "Not recognized" for GDB.
编辑2:我记得我使用MSVC编译器,Qt库是为MSVC编译的:
Edit 2: I just remembered that I'm using the MSVC compiler, and the Qt libs are compiled for MSVC:
>
也许这是原因?虽然GDB应该能够调试任何可执行文件,而不只是由gcc生成的那些,所以我不知道它是否相关。
Maybe that's the reason? Although GDB should be able to debug any executable, not just ones generated by gcc, so I'm not sure if it's relevant.
推荐答案
p>您不能将GDB与MSVC编译的代码一起使用。看起来你正在混合这两个。
You can't use GDB with MSVC-compiled code. It seems you're mixing the two.
CDB与Visual C ++一起使用。 GDB与MinGW(-w64)一起使用。
CDB goes with Visual C++. GDB goes with MinGW(-w64).
这篇关于在Windows上无法在Qt Creator中选择GDB的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!