0
我有一个程序,我开始在Linux Debian上,所以链接很容易。我所要做的只是命令行:链接增强内存映射文件
LIBS += -lboost_system -lboost_iostreams
现在我必须在Windows上编译相同的程序。我下载了升级版本1.58,然后执行bootstrap
,然后bjam
。这编译提升并创建了包含所有库的stage
文件夹。
现在我使用内存映射文件类boost::iostreams::mapped_file_source()
,所以我越来越多链接错误,从中我提到作为一个例子:
FileCheck.obj:-1: error: LNK2019: unresolved external symbol "public: char const * __cdecl boost::iostreams::mapped_file_source::data(void)const " ([email protected][email protected]@[email protected]@QEBAPEBDXZ) referenced in function "class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __cdecl MD5FromFile(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)" ([email protected]@[email protected][email protected]@[email protected]@[email protected]@[email protected]@[email protected]@[email protected]@Z)
我试图链接,以提高这一点。所以我加了助手的路径和:
LIBS += -L"X:/Path/to/boost/boost_1_58_0/stage/lib"
LIBS += -llibboost_system-vc120-mt-1_58 -llibboost_iostreams-vc120-mt-1_58
LIBS += -llibboost_system-vc120-mt-gd-1_58 -llibboost_iostreams-vc120-mt-gd-1_58
但是我仍然得到这个错误。现在我想指出编译器(VS2013)找到lib文件,但它显然是不够的。
我也想提一提,我用升压:: ASIO也和OpenSSL,但是没有问题,这些链接。
不知道如何联系起来,提升内存映射文件?
谢谢。
当然关于32或64位库版本?如果你在32中编译并且库在64中可以出现。 你有没有检查符号是否存在于库中? – eroween
@ LouisMartin-Pierrat你是对的!非常感谢:) –
与Windows构建玩得开心。我在这里等你。 – eroween