简体   繁体   English

MSVC QT Creator - 如何正确设置CDB?

[英]MSVC QT Creator - How to setup CDB correctly?

So I re installed my system and I am having huge problems with the MSVC debbugging. 所以我重新安装了我的系统,我遇到了MSVC debbugging的巨大问题。 I can compile my application no problem. 我可以编译我的应用程序没问题。 I have followed the instructions for QT creator setting up debugging with CDB on Windows 7. 我已按照QT创建者的说明在Windows 7上使用CDB设置调试

  1. I installed MS Visual Studio 2010 and updates 我安装了MS Visual Studio 2010并进行了更新
  2. I uninstalled 2010 C++ runtimes. 我卸载了2010 C ++运行时。
  3. I installed the Windows debugging tools and SDK. 我安装了Windows调试工具和SDK。
  4. I also re-updated 2010 runtimes. 我还重新更新了2010运行时。

After all this I now have the CDB debugger. 毕竟,我现在有了CDB调试器。

C:\Program Files\Debugging Tools for Windows (x64)\cdb.exe

In QT it auto detects the cdb.exe, this is what my kit looks like. 在QT中,它会自动检测cdb.exe,这就是我的工具包的样子。

QT设置

When trying to run a debug session it simply starts and quits. 尝试运行调试会话时,它只是启动并退出。

Debugging starts
Debugging has finished

The anwser is kind of silly, when you install QT creator you need to create at least one project first without anything setup. anwser有点傻,当您安装QT创建者时,您需要先创建至少一个项目而不进行任何设置。 If you import a project without doing this first everything will fail. 如果您在不执行此操作的情况下导入项目,则一切都将失败 So the exact steps I took to get this to work are.... 所以我采取的确切步骤是......

1) I installed VS 2010 1)我安装了VS 2010

2) Update VS 2010 to SP1 2)将VS 2010更新到SP1

3) Update Windows and .NET 3)更新Windows和.NET

4) uninstall 2010 C++ redistributables 1.4 or newer 4)卸载2010 C ++可再发行组件1.4或更新版本

5) install Windows debugging tools and SDK for Windows 7 5)安装适用于Windows 7的Windows调试工具和SDK

6) install QT libs 6)安装QT库

7) install QT creator 7)安装QT创建者

8) create C++ code snippet project 8)创建C ++代码片段项目

9) setup Compiler and Debbuger with CDB 64 bit 9)使用CDB 64位设置编译器和Debbuger

The 64 Bit CDB works in 32 bit mode as well. 64位CDB也可以在32位模式下工作。

I was having a similar problem, it turns out it was not set to the x64 version. 我遇到了类似的问题,事实证明它没有设置为x64版本。 So basically: Tools->Options->Kits->Qt 5.xx->Debugger and set it to the one ending with "x64\\cdb.exe" 所以基本上:工具 - >选项 - >套件 - > Qt 5.xx->调试器并将其设置为以“x64 \\ cdb.exe”结尾的一个

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

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