id summary reporter owner description type status milestone component version severity resolution keywords cc 12974 Log and Asio without defined _WIN32_WINNT sobolevsv@… chris_kohlhoff "platform: Win10, VC14, boost 1.64 Using Log and Asio simultaneously cause link errors depending on order of includes. if _WIN32_WINNT not defined and there are several translation units, most of it use only Log and some use both Log and Asio I get link error if Log includes come first followed by Asio, building complete successfull[[BR]] for example {{{ #include #include #include }}} but if Asio include comes before Log includes[[BR]] for example {{{ #include #include #include }}} I get link error: LNK2038: mismatch detected for 'boost_log_abi': value 'v2s_mt_nt5' doesn't match value 'v2s_mt_nt6' in gtclient.obj this message generated by #pragma detect_mismatch in boost\log\detail\config.hpp : {{{ #if defined(BOOST_LOG_HAS_PRAGMA_DETECT_MISMATCH) #pragma detect_mismatch(""boost_log_abi"", BOOST_PP_STRINGIZE(BOOST_LOG_VERSION_NAMESPACE)) #endif }}} it happend becase Log and Asio use different macros to define target Windows version.[[BR]] Log use BOOST_USE_WINAPI_VERSION[[BR]] but Asio use _WIN32_WINNT in \boost\asio\detail\config.hpp [[BR]] Asio checks if _WIN32_WINNT defined. if not, it defines it {{{ # define _WIN32_WINNT 0x0501 }}} BOOST_USE_WINAPI_VERSION defined in boost\detail\winapi\config.hpp it depends on _WIN32_WINNT and _MSC_VER {{{ #if !defined(BOOST_USE_WINAPI_VERSION) #if defined(_WIN32_WINNT) #define BOOST_USE_WINAPI_VERSION _WIN32_WINNT #elif defined(WINVER) #define BOOST_USE_WINAPI_VERSION WINVER #else // By default use Windows Vista API on compilers that support it and XP on the others #if (defined(_MSC_VER) && _MSC_VER < 1500) || defined(BOOST_WINAPI_IS_MINGW) #define BOOST_USE_WINAPI_VERSION BOOST_WINAPI_VERSION_WINXP #else #define BOOST_USE_WINAPI_VERSION BOOST_WINAPI_VERSION_WIN6 #endif #endif #endif }}} I think this error appeared in boost 1.60 when Log started using BOOST_USE_WINAPI_VERSION http://www.boost.org/users/history/version_1_60_0.html if I define _WIN32_WINNT=0x0A00 in compiler option, there are no link error with any includes ordering." Bugs new To Be Determined asio Boost 1.64.0 Problem Win10 VC14 sobolevsv@…