【问题标题】:Any way to fix "command timed out" GDB error for an SFML-using program in CLion?有什么方法可以修复 CLion 中使用 SFML 的程序的“命令超时”GDB 错误?
【发布时间】:2016-10-23 08:14:24
【问题描述】:

问题是 GDB 无法从使用 SFML 的程序的某些地方获取调试信息。 CLion 规格:

  • CLion 2016.1.3
  • MinGW-w64 3.4
  • GDB 7.8.1

我找到了一个建议停止杀毒软件一段时间的答案,但它不起作用。

代码示例:

int main(int argc, char* argv[]) {

    sf::RenderWindow window(sf::VideoMode(800, 600), "myproject");

    Interface interface (window);
    /* Setting up 'interface'*/

    while (window.isOpen()) {
        sf::Event event;
        while (window.pollEvent(event)) {
            /* Capture events */
        }
        window.clear ();
        interface.draw (); // Breakpoint here, information captured instantly
    }
}

进入 interface.draw():

void draw () {
    for (FramePtr &ptr : activeFrameStack) // Debugger fails to get info here
        ptr->draw (window);
}

【问题讨论】:

    标签: c++ sfml clion


    【解决方案1】:

    获取最近发布的 2016.2 版本,修复了“命令超时”问题并将捆绑的 GDB 更新到 7.11 (https://blog.jetbrains.com/clion/2016/07/clion-2016-2-released/)。

    【讨论】:

    猜你喜欢
    • 2017-02-10
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2019-11-23
    • 2017-07-01
    相关资源
    最近更新 更多