Use BOOST_THREAD_DYN_LINK instead of BOOST_THREAD_DYN_DLL for compatibility with the rest of boost. Fix for issue #2874