gpt4 book ai didi

c++ - 在 qt 中切换编译器后出现错误

转载 作者:塔克拉玛干 更新时间:2023-11-03 08:00:31 33 4
gpt4 key购买 nike

将 qt 中的默认编译器切换到 gcc 4.6.2 后,出现以下错误:

c:\ndk_buildrepos\qt-desktop\src\winmain\qtmain_win.cpp:93: error: undefined reference to `_Unwind_Resume'

使用编译器开关我还做了两件事 - 我用 gcc 4.6.2 中的 make 覆盖了 mingw32make。我对干净的步骤做了同样的事情。

有办法解决吗?

最佳答案

_unwind_resume 是编译器运行时库的一部分 - 它在处理异常时处理展开堆栈。

此帖http://www.linuxquestions.org/questions/linux-newbie-8/undefined-symbol-_unwind_resume-192813/建议链接库 gcc_s ( -lgcc_s )

这是一个类似的解决方案:http://www.pgroup.com/userforum/viewtopic.php?t=1636&sid=a1f1e9e649686d97a21ba367284ea3ce

有人在使用 QT 时遇到同样的问题:http://www.qtcentre.org/threads/33394-Link-errors-undefined-reference-to-_Unwind_Resume-and-__gxx_personality_v0 .他们说“运行 C:\Qt\2010.04\bin\qtenv.bat 解决了这个问题。”

关于c++ - 在 qt 中切换编译器后出现错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8307161/

33 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com