【问题标题】:cconfig.obj and cutility.obj error lnk2001. Cannot find any info on those 2 obj filescconfig.obj 和 cutility.obj 错误 lnk2001。找不到关于这 2 个 obj 文件的任何信息
【发布时间】:2021-02-27 09:07:35
【问题描述】:

我在 QTcreator 上编译时一直遇到问题。它是基于 qt3 代码的 QT4。 我解决了我遇到的大部分问题,但我遇到了这个问题。

22:54:57: Running steps for project brickstock... 
22:54:57: Starting: "C:\Qt\4.8.7\bin\qmake.exe" C:\bl\brickstock-1.2.13-src\brickstock.pro -r -spec win32-msvc2010 "CONFIG+=release"
22:54:58: The process "C:\Qt\4.8.7\bin\qmake.exe" exited normally.
22:54:58: Starting: "C:\Qt\Tools\QtCreator\bin\jom.exe" 

    C:\Qt\Tools\QtCreator\bin\jom.exe -f Makefile.Release
    link /LIBPATH:"c:\Qt\4.8.7\lib" /NOLOGO /DYNAMICBASE /NXCOMPAT /INCREMENTAL:NO /MANIFEST /MANIFESTFILE:".obj\brickstock.intermediate.manifest" /SUBSYSTEM:WINDOWS "/MANIFESTDEPENDENCY:type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' publicKeyToken='6595b64144ccf1df' language='*' processorArchitecture='*'" /OUT:release\brickstock.exe @C:\Users\Charles\AppData\Local\Temp\brickstock.exe.1172.47.jom
bricklink.obj : MSIL .netmodule or module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance

cconfig.obj : error LNK2001: unresolved external symbol __imp__RegQueryValueExW@24

cconfig.obj : error LNK2001: unresolved external symbol __imp__RegOpenKeyExW@20

cconfig.obj : error LNK2001: unresolved external symbol __imp__SHGetSpecialFolderPathW@16

cconfig.obj : error LNK2001: unresolved external symbol __imp__RegCloseKey@4

cutility.obj : error LNK2001: unresolved external symbol __imp__ShellExecuteW@24

release\brickstock.exe : fatal error LNK1120: 5 unresolved externals

jom: C:\bl\build-brickstock-4_8_7-Release\Makefile.Release [release\brickstock.exe] Error 1120

jom: C:\bl\build-brickstock-4_8_7-Release\Makefile [release] Error 2

22:55:00: The process "C:\Qt\Tools\QtCreator\bin\jom.exe" exited with code 2.

Error while building/deploying project brickstock (kit: 4.8.7)

The kit 4.8.7 has configuration issues which might be the root cause for this problem.
When executing step "Make"
22:55:00: Elapsed time: 00:03.

我有 cconfig.h 和 cutility.h 但我找不到关于 cconfig.obj 或 cutility.obj 的任何信息。

【问题讨论】:

  • 通过添加修复它

标签: c++ qt4 qt-creator


【解决方案1】:

通过添加修复它:

#pragma comment(lib, "SHELL32.LIB")

#pragma comment(lib, "Advapi32.lib")

在 cconfig.cpp强文本

【讨论】:

    猜你喜欢
    • 2021-11-24
    • 1970-01-01
    • 1970-01-01
    • 2021-09-25
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多