Visual c++ Boost:虽然已编译,但缺少lib 我在VisualC++项目中编译了Boost和AM。在某个时候,我开始出现以下错误: 1>LINK : fatal error LNK1104: cannot open file 'libboost_filesystem-vc100-mt-sgd-1_45.lib'

Visual c++ Boost:虽然已编译,但缺少lib 我在VisualC++项目中编译了Boost和AM。在某个时候,我开始出现以下错误: 1>LINK : fatal error LNK1104: cannot open file 'libboost_filesystem-vc100-mt-sgd-1_45.lib',visual-c++,boost,linker-errors,Visual C++,Boost,Linker Errors,好的,我已经正确设置了链接器配置。我搜索了lib并找到了一些相近的匹配项: $(LIB_BOOST)\stage\lib\libboost_filesystem-vc100-mt-gd-1_45.lib $(LIB_BOOST)\stage\lib\libboost_filesystem-vc100-mt-gd.lib $(LIB_BOOST)\stage\lib\libboost_filesystem-vc100-mt-1_45.lib $(LIB_BOOST)\stage\lib\libbo

好的,我已经正确设置了链接器配置。我搜索了lib并找到了一些相近的匹配项:

$(LIB_BOOST)\stage\lib\libboost_filesystem-vc100-mt-gd-1_45.lib
$(LIB_BOOST)\stage\lib\libboost_filesystem-vc100-mt-gd.lib
$(LIB_BOOST)\stage\lib\libboost_filesystem-vc100-mt-1_45.lib
$(LIB_BOOST)\stage\lib\libboost_filesystem-vc100-mt.lib
$(LIB_BOOST)\bin.v2\libs\filesystem\build\msvc-10.0\release\link-static\threading-multi\libboost_filesystem-vc100-mt-1_45.lib
$(LIB_BOOST)\bin.v2\libs\filesystem\build\msvc-10.0\debug\link-static\threading-multi\libboost_filesystem-vc100-mt-gd-1_45.lib
(请注意其中大多数缺少的“s”)

缺失的“s”代表什么?这些相似但不同的LIB代表什么?尽管我已经编译了Boost的所有部分,但为什么我会错过它呢?

's'是其中之一

ABI标记:对影响 图书馆与图书馆的互操作性 其他编译代码。每种 功能中,将向中添加一个字母 标签:

例如,如果生成调试 用于的代码版本 静态运行时的调试版本 图书馆与STLPort标准 “本机iostreams”模式下的库, 标签应该是:-sgdpn。如果没有 上述情况适用,ABI标签为 奥米特


我添加了命令行选项:运行时链接=共享,静态 其中包括丢失的s文件


希望对您有所帮助

按照您的指示,我使用BoostPro安装程序重新安装了Boost。我选择同时安装static\debug\multi-threaded和static\multi-threaded。事实上,我后来并没有错过这个库。@Jonathan:如果您使用--build type=complete构建boost库,那么它将构建所有受支持的变体。参见中的“5.3.4调用bjam”
    Key     Use this library when:
    s   linking statically to the C++ standard library and compiler runtime support libraries.
    g   using debug versions of the standard and runtime support libraries.
    y   using a special debug build of Python.
    d   building a debug version of your code.7
    p   using the STLPort standard library rather than the default one supplied with your compiler.
    n   using STLPort's deprecated “native iostreams” feature.8