Chromium Embedded Framework不会构建或运行

ben*_*pas 9 windows chromium chromium-embedded

我正在https://bitbucket.org/chromiumembedded/cef/wiki/Tutorial上试用CEF wikipage上的Windows教程.

但是,32位和64位的CEF构建将无法在Visual Studio 2010上构建/运行.

顺便说一句,我正在运行Windows 7(64位)和Visual Studio 2010.

以下是错误:

32位构建

- error LNK2038: mismatch detected for '_MSC_VER': value '1800' doesn't match value '1600' in simple_app.obj
- (A THOUSAND LINES OF ERRORS)
- out\Debug\cefsimple.exe : fatal error LNK1120: 11 unresolved externals
Run Code Online (Sandbox Code Playgroud)

64位构建

- out\Debug\obj\libcef_dll_wrapper\transfer_util.obj : fatal error LNK1112: module machine type 'X86' conflicts with target machine type 'x64'
- LINK : fatal error LNK1104: cannot open file 'C:\Users\Benj\Desktop\Blueprint Gaming\Chromium Embedded Framework\64 Bit\cef_binary_3.1921.1661_windows64\out\Debug\lib\libcef_dll_wrapper.lib'
Run Code Online (Sandbox Code Playgroud)

Sha*_*adh 20

我假设您指的是与库捆绑在一起的cef_simple或cef_client项目......

固定

在cef_simple.cpp和cefclient_win.cpp中将CEF_ENABLE_SANDBOX的宏值设置为0

发生了什么

该错误表示您链接的库与simple_app.obj不兼容.在这种情况下,这个库(cef_sandbox.lib)使用_MSC_VER 1800(即VS2013测试版,如果我没有错)构建,而您当前的环境是_MSC_VER 1600(VS2010).

几天前也有同样的问题 - 干杯!

  • CEF_ENABLE_SANDBOX常量现在位于`/ cefsimple/cefsimple_win.cpp`和`/ cefclient/cefclient_win.cpp`中 (4认同)