2011-09-18 43 views
0

我试图建立的MongoDB C++ 2.0驱动程序,但有以下错误信息:不能编译的MongoDB 2.0 C++司机

security_commands.cpp :(文字+ 0x865):未定义参考 mongo::CmdAuthenticate::getUserObj(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, mongo::BSONObj&, std::basic_string<char, std::char_traits<char>, std::allocator<char> >&)' security_commands.cpp:(.text+0xa59): undefined reference to 蒙戈:: CmdAuthenticate ::的authenticate(性病:: basic_string的,标准::分配器>常量&, 的std :: basic_string的,标准::分配器> 常量&,布尔)”蒙戈/分贝/ security_commands.os:在功能 _GLOBAL__sub_I_security_commands.cpp': security_commands.cpp:(.text.startup+0x1a6): undefined reference to vim for mongo :: CmdLogout'mongo/db/security_common.os:在函数 `mongo :: AuthenticationInfo :: _ isAut horized(性病:: basic_string的,性病::分配器>常量&,INT)常量“:

+1

你没有链接到正确的库 – flumpb

回答

1

驱动程序压缩包似乎缺少等等蒙戈/ DB/security.cpp文件做一个共享库。

但是,它足够用于构建带有少量缺失符号的静态库。

开放SConstruct和注释掉该行称

库+ = env.SharedLibrary( “mongoclient”,allClientFiles)

和你设置。