首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >如何使用Visual 2017编译CEF库?

如何使用Visual 2017编译CEF库?
EN

Stack Overflow用户
提问于 2018-11-07 08:32:52
回答 1查看 1.4K关注 0票数 2

我遵循Sga的答案How to use Chromium Embedded Framework with Visual Studio 2017 (C++)?,用VisualStudio2017编译Cef。但是,当我遵循他的步骤7. Build /Release时,我得到了以下错误:

代码语言:javascript
复制
Severity    Code    Description Project File    Line    Suppression State
Error   LNK2019 unresolved external symbol _CLSID_WbemLocator referenced in function "bool __cdecl base::win::CreateLocalWmiConnection(bool,class Microsoft::WRL::ComPtr<struct IWbemServices> *)" (?CreateLocalWmiConnection@win@base@@YA_N_NPAV?$ComPtr@UIWbemServices@@@WRL@Microsoft@@@Z)   cefsimple   C:\Users\BremeyeT\source\repos\cef_binary_3.3538.1849.g458cc98_windows32\build\tests\cefsimple\cef_sandbox.lib(wmi.obj) 1   
Error   LNK1120 1 unresolved externals  cefsimple   C:\Users\BremeyeT\source\repos\cef_binary_3.3538.1849.g458cc98_windows32\build\tests\cefsimple\Debug\cefsimple.exe  1   
Error   LNK2019 unresolved external symbol _CLSID_WbemLocator referenced in function "bool __cdecl base::win::CreateLocalWmiConnection(bool,class Microsoft::WRL::ComPtr<struct IWbemServices> *)" (?CreateLocalWmiConnection@win@base@@YA_N_NPAV?$ComPtr@UIWbemServices@@@WRL@Microsoft@@@Z)   cefclient   C:\Users\BremeyeT\source\repos\cef_binary_3.3538.1849.g458cc98_windows32\build\tests\cefclient\cef_sandbox.lib(wmi.obj) 1   
Error   LNK1120 1 unresolved externals  cefclient   C:\Users\BremeyeT\source\repos\cef_binary_3.3538.1849.g458cc98_windows32\build\tests\cefclient\Debug\cefclient.exe  1   
Error   LNK2019 unresolved external symbol _CLSID_WbemLocator referenced in function "bool __cdecl base::win::CreateLocalWmiConnection(bool,class Microsoft::WRL::ComPtr<struct IWbemServices> *)" (?CreateLocalWmiConnection@win@base@@YA_N_NPAV?$ComPtr@UIWbemServices@@@WRL@Microsoft@@@Z)   ceftests    C:\Users\BremeyeT\source\repos\cef_binary_3.3538.1849.g458cc98_windows32\build\tests\ceftests\cef_sandbox.lib(wmi.obj)  1   
Error   LNK1120 1 unresolved externals  ceftests    C:\Users\BremeyeT\source\repos\cef_binary_3.3538.1849.g458cc98_windows32\build\tests\ceftests\Debug\ceftests.exe

我从this question了解到这与wbemuuid.lib有关。所以我加入了

$(UniversalCRT_LibraryPath_x86)....\um\x86

到项目cefclient、cefsimple和ceftest的库目录,因为这是我在驱动器中找到wbemuuid.lib的地方。然而,Cef库仍未成功编译,并显示相同的错误。

我确实检查了我正在编译库的Win32版本,而wbemuuid.lib是32位版本。

为了获得一个成功的编译和链接,我还需要做什么呢?

EN

回答 1

Stack Overflow用户

发布于 2018-12-01 18:22:54

您需要链接到wbemuuid.lib

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/53185835

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档