关于boost库的一个auto_link问题?
C:\Program Files\boost_1_47_0\boost/config/auto_link.hpp(258): catastrophic error: #error directive: "Build options aren't compatible with pre-built libraries"
1> # error "Build options aren't compatible with pre-built libraries"
这是提示错误:
错误定位:
if (defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION)) && (defined(_STLP_OWN_IOSTREAMS) || defined(__STL_OWN_IOSTREAMS))
# if defined(_DEBUG) && (defined(__STL_DEBUG) || defined(_STLP_DEBUG))\
&& defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON)
# define BOOST_LIB_RT_OPT "-sgydp"
# elif defined(_DEBUG) && (defined(__STL_DEBUG) || defined(_STLP_DEBUG))
# define BOOST_LIB_RT_OPT "-sgdp"
# elif defined(_DEBUG)\
&& defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON)
# define BOOST_LIB_RT_OPT "-sgydp"
# pragma message("warning: STLPort debug versions are built with /D_STLP_DEBUG=1")
# error "Build options aren't compatible with pre-built libraries"
# elif defined(_DEBUG)
# define BOOST_LIB_RT_OPT "-sgdp"
# pragma message("warning: STLPort debug versions are built with /D_STLP_DEBUG=1")
# error "Build options aren't compatible with pre-built libraries" <------------此处定位错误!!!
# else
# define BOOST_LIB_RT_OPT "-sp"
# endif
我只在cpp文件里面写了一行字;#include <boost/regex/concepts.hpp>
然后编译+链接,就这样了!