【VS开发】【C/C++开发】关于boost库的C++11导致的undefined符号问题

undefined reference to boost::program_options::options_description::m_default_line_length

问题最终解决依靠的是如下的问题:

Visual Studio 2015: 版本boost_1_61_0有问题,重新利用Visual C++ 2015 x64编译也没用;

更新版本为boost_1_65_1后,利用x64编译则没问题 。

参考的解决方案说明如下:

There were changes to the <string> class in the C++11 standard which may conflict with versions of the Boost library that were compiled with a non-C++11 compiler (such as G++-4.8). Try recompiling boost or using a version of C++ compiler that was used to compile your Boost libraries

http://www.boost.org/官网上对新版本的描述如下:

We aim to establish "existing practice" and provide reference implementations so that Boost libraries are suitable for eventual standardization. Ten Boost libraries are included in the C++ Standards Committee's Library Technical Report (TR1) and in the new C++11 Standard. C++11 also includes several more Boost libraries in addition to those from TR1. More Boost libraries are proposed for standardization in C++17.


--------------

张朋艺 [email protected]

2017-12-08

猜你喜欢

转载自blog.csdn.net/lg1259156776/article/details/78750290