找不到atlbase.h(VS2008)

时间:2011-08-09 21:09:19

标签: c++ visual-studio-2008 atl winapi

基本上,我正在尝试在VS2008 EE上编译CEF

IDE抱怨找不到atlbase.h。在一些研究中,我发现了reference。 考虑到这不是我第一次给C ++另一次机会,我已经安装了WinSDK并不感到惊讶。但是,当然,IDE并不知道这一点,并且SDK注册工具似乎不起作用(即使它说它确实如此)。

所以,我去了项目选项并强制添加到WinSDK源文件夹的路径。 这帮我摆脱了“atlbase.h not found”错误。相反,我开始有多个错误;事实上,其中一些是相当神秘的抱怨_Module之类的东西没有被定义。

这些是错误:

Compiling...
uiplugin_test.cpp
uiplugin.cpp
string_util.cpp
scheme_test.cpp
resource_util_win.cpp
plugin_test.cpp
SDK\Include\atl\atlwin.h(65) : error C2065: '_Module' : undeclared identifier
SDK\Include\atl\atlwin.h(79) : error C2065: '_Module' : undeclared identifier
SDK\Include\atl\atlwin.h(155) : error C2065: '_Module' : undeclared identifier
SDK\Include\atl\atlwin.h(155) : error C2228: left of '.GetModuleInstance' must have class/struct/union
        type is ''unknown-type''
SDK\Include\atl\atlwin.h(168) : error C2065: '_Module' : undeclared identifier
SDK\Include\atl\atlwin.h(168) : error C2228: left of '.GetModuleInstance' must have class/struct/union
        type is ''unknown-type''
SDK\Include\atl\atlwin.h(1753) : error C2065: 'i' : undeclared identifier
SDK\Include\atl\atlwin.h(1753) : error C2065: 'i' : undeclared identifier
SDK\Include\atl\atlwin.h(1753) : error C2065: 'i' : undeclared identifier
SDK\Include\atl\atlwin.h(1755) : error C2065: 'i' : undeclared identifier
SDK\Include\atl\atlwin.h(1757) : error C2065: 'i' : undeclared identifier
SDK\Include\atl\atlwin.h(2979) : error C2065: '_Module' : undeclared identifier
SDK\Include\atl\atlwin.h(2979) : error C2228: left of '.GetModuleInstance' must have class/struct/union
        type is ''unknown-type''
SDK\Include\atl\atlwin.h(3058) : error C2065: '_Module' : undeclared identifier
SDK\Include\atl\atlwin.h(3058) : error C2228: left of '.GetModuleInstance' must have class/struct/union
        type is ''unknown-type''
osrplugin_test.cpp
osrplugin.cpp
extension_test.cpp
download_handler.cpp
clientplugin.cpp
SDK\Include\atl\atlwin.h(65) : error C2065: '_Module' : undeclared identifier
SDK\Include\atl\atlwin.h(79) : error C2065: '_Module' : undeclared identifier
SDK\Include\atl\atlwin.h(155) : error C2065: '_Module' : undeclared identifier
SDK\Include\atl\atlwin.h(155) : error C2228: left of '.GetModuleInstance' must have class/struct/union
        type is ''unknown-type''
SDK\Include\atl\atlwin.h(168) : error C2065: '_Module' : undeclared identifier
SDK\Include\atl\atlwin.h(168) : error C2228: left of '.GetModuleInstance' must have class/struct/union
        type is ''unknown-type''
SDK\Include\atl\atlwin.h(1753) : error C2065: 'i' : undeclared identifier
SDK\Include\atl\atlwin.h(1753) : error C2065: 'i' : undeclared identifier
SDK\Include\atl\atlwin.h(1753) : error C2065: 'i' : undeclared identifier
SDK\Include\atl\atlwin.h(1755) : error C2065: 'i' : undeclared identifier
SDK\Include\atl\atlwin.h(1757) : error C2065: 'i' : undeclared identifier
SDK\Include\atl\atlwin.h(2979) : error C2065: '_Module' : undeclared identifier
SDK\Include\atl\atlwin.h(2979) : error C2228: left of '.GetModuleInstance' must have class/struct/union
        type is ''unknown-type''
SDK\Include\atl\atlwin.h(3058) : error C2065: '_Module' : undeclared identifier
SDK\Include\atl\atlwin.h(3058) : error C2228: left of '.GetModuleInstance' must have class/struct/union
        type is ''unknown-type''
client_popup_handler.cpp
client_handler_win.cpp
client_handler.cpp
cefclient_win.cpp
.\cefclient_win.cpp(296) : error C3861: 'wcscpy_s': identifier not found
cefclient.cpp
SDK\Include\crt\utility(21) : error C2536: 'std::pair<_T1,_T2>::std::pair<_T1,_T2>::first' : cannot specify explicit initializer for arrays
        with
        [
            _T1=const char [12],
            _T2=const char [16]
        ]
        SDK\Include\crt\utility(24) : see declaration of 'std::pair<_T1,_T2>::first'
        with
        [
            _T1=const char [12],
            _T2=const char [16]
        ]
        SDK\Include\crt\utility(20) : while compiling class template member function 'std::pair<_T1,_T2>::pair(_T1 (&),_T2 (&))'
        with
        [
            _T1=const char [12],
            _T2=const char [16]
        ]
        .\cefclient.cpp(92) : see reference to class template instantiation 'std::pair<_T1,_T2>' being compiled
        with
        [
            _T1=const char [12],
            _T2=const char [16]
        ] SDK\Include\crt\utility(21) : error C2536: 'std::pair<_T1,_T2>::std::pair<_T1,_T2>::second' : cannot specify explicit initializer for arrays
        with
        [
            _T1=const char [12],
            _T2=const char [16]
        ]
        SDK\Include\crt\utility(25) : see declaration of 'std::pair<_T1,_T2>::second'
        with
        [
            _T1=const char [12],
            _T2=const char [16]
        ]
binding_test.cpp

2 个答案:

答案 0 :(得分:-1)

您是否尝试过关注Chromium的Build Instructions (Windows)?特别是处理Visual Studio 2008 Express(项目4 here)的附加(免费)下载下的部分。

答案 1 :(得分:-5)

我找到了解决这个问题的方法。几分钟前,我意识到他们也有Delphi的工作版本。

几分钟后,我的Delphi安装配置了正确的路径,现在它构建得很好。