我需要一些 boost 库的动态可链接构建,wave 就是其中之一。使用 b2.exe 命令行工具时,某些库将无法构建(其中包括 wave)。这是我用于命令行参数的:
C:\boost>b2.exe --toolset=msvc-10.0 --build-type=complete --with-chrono --with-date_time --with-thread --with-wave link=shared architecture=x86 address-model=64
从输出中我可以推断出线程组件存在问题:
.
...removing bin.v2\libs\thread\build\msvc-10.0\debug\address-model-64\architectu
re-x86\threading-multi\boost_thread-vc100-mt-gd-1_50.lib
...removing bin.v2\libs\thread\build\msvc-10.0\debug\address-model-64\architectu
re-x86\threading-multi\boost_thread-vc100-mt-gd-1_50.pdb
...skipped <pbin.v2\libs\wave\build\msvc-10.0\debug\address-model-64\architectur
e-x86\threading-multi>boost_wave-vc100-mt-gd-1_50.dll for lack of <pbin.v2\libs\
thread\build\msvc-10.0\debug\address-model-64\architecture-x86\threading-multi>b
oost_thread-vc100-mt-gd-1_50.lib...
并且该线程似乎与其他符号有问题(可能来自日期时间):
thread.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) pu
blic: __cdecl boost::gregorian::greg_month::greg_month(unsigned short)" (__imp_?
?0greg_month@gregorian@boost@@QEAA@G@Z) referenced in function "public: __cdecl
boost::gregorian::date::date(enum boost::date_time::special_values)" (??0date@gr
egorian@boost@@QEAA@W4special_values@date_time@2@@Z)
thread.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) pu
blic: __cdecl boost::gregorian::greg_month::operator unsigned short(void)const "
(__imp_??Bgreg_month@gregorian@boost@@QEBAGXZ) referenced in function "union _L
ARGE_INTEGER __cdecl boost::this_thread::`anonymous namespace'::get_due_time(str
uct boost::detail::timeout const &)" (?get_due_time@?A0x8352ecf9@this_thread@boo
st@@YA?AT_LARGE_INTEGER@@AEBUtimeout@detail@3@@Z)
寻找这些问题的解决方案的首要位置是什么?有没有人遇到过类似的问题?