我正在尝试使用Visual Studio 2013构建Boost 1.55.
1)我尝试使用boost-binaries(boost-binaries),但是当我尝试编译时,Visual Studio写了关于错误的信息:
错误LNK1104:无法打开文件'libboost_serialization-vc120-mt-gd-1_55.lib'.我使用了boost_1_55_0-msvc-12.0-32.exe或1.55.0-build2(boost-binaries).
我没有在boost_1_55_0\lib32-msvc-12.0目录中找到.lib文件.
2)我也尝试使用这个程序BlueGo 0.1.7(BlueGo).它工作非常顺利,并创建我需要的所有库.
问题在于它创建了像这样的.lib文件:
libboost_serialization-vc110-MT-GD-1_55.lib
但我使用Visual Studio 2013并且需要使用vc120版本的编译器而不是vc110,过度使用它会引发错误.
3)最后我决定自己创建dll/lib文件.
我在boost站点中使用了以下指南: Simplified Build From Source.
如果您希望使用Visual C++从源代码构建,可以使用本节中描述的简单构建过程.打开命令提示符并将当前目录更改为Boost根目录.然后,键入以下命令:
bootstrap
.\b2
Run Code Online (Sandbox Code Playgroud)
上面我写了,我需要做什么.
我启动了"VS2012 x86 Native Tools命令提示符",将dir更改为boost root目录并输入命令:
bootstrap
Run Code Online (Sandbox Code Playgroud)
我马上得到了错误:
C:\thirdparty\vs2013\x86\boost_1_55_0>.\bootstrap.bat
Building Boost.Build engine
Failed to build Boost.Build engine.
Please consult bootstrap.log for furter diagnostics.
You can try to obtain a prebuilt binary from
http://sf.net/project/showfiles.php?group_id=7586&package_id=72941
Also, you can file an issue at http://svn.boost.org
Please attach bootstrap.log in that case.
Run Code Online (Sandbox Code Playgroud)
在日志文件中,我注意到以下错误:
execnt.c(56):致命错误C1083:无法打开包含文件:'tlhelp32.h':没有这样的文件或目录
bootstrap.log文件: …