I am using b2.exe to compile Boost.DateTime:
.\b2.exe install --with-date_time link=static runtime-link=static It create bin.v2 directory in C\:Downloads\boost_1_66_0, I copy static lib libboost_date_time-vc141-mt-gd-x32-1_66.lib from bin.v2\libs\date_time\build\msvc-14.1\debug\link-static\threadapi-win32\threading-multi to my project
and copy all of the headers from C\:Downloads\boost_1_66_0\boost to my project
I am try to include #include "boost/date_time.hpp" with error
error(active) E1696 cannot open source file "boost/cstdint.hpp" ConsoleApplication1 c : \Users\Administrator\source\repos\ConsoleApplication1\ConsoleApplication1\include\boost\date_time\posix_time\posix_time_config.hpp 14 Error(active) E1696 cannot open source file "boost/config/no_tr1/cmath.hpp" ConsoleApplication1 c : \Users\Administrator\source\repos\ConsoleApplication1\ConsoleApplication1\include\boost\date_time\posix_time\posix_time_config.hpp 15 Error(active) E1696 cannot open source file "boost/cstdint.hpp" ConsoleApplication1 c : \Users\Administrator\source\repos\ConsoleApplication1\ConsoleApplication1\include\boost\date_time\time_duration.hpp 12 Error(active) E1696 cannot open source file "boost/operators.hpp" ConsoleApplication1 c : \Users\Administrator\source\repos\ConsoleApplication1\ConsoleApplication1\include\boost\date_time\time_duration.hpp 13 Error(active) E1696 cannot open source file "boost/static_assert.hpp" ConsoleApplication1 c : \Users\Administrator\source\repos\ConsoleApplication1\ConsoleApplication1\include\boost\date_time\time_duration.hpp 14 Error(active) E0169 expected a declaration ConsoleApplication1 c : \Users\Administrator\source\repos\ConsoleApplication1\ConsoleApplication1\include\boost\date_time\time_duration.hpp 289 Error(active) E1696 cannot open source file "boost/cstdint.hpp" ConsoleApplication1 c : \Users\Administrator\source\repos\ConsoleApplication1\ConsoleApplication1\include\boost\date_time\time_resolution_traits.hpp 13 Error(active) E0020 identifier "time_resolution_traits_adapted32_impl" is undefined ConsoleApplication1 c : \Users\Administrator\source\repos\ConsoleApplication1\ConsoleApplication1\include\boost\date_time\time_resolution_traits.hpp 135 Error LNK1104 cannot open file 'libboost_date_time-vc141-mt-sgd-x32-1_66.lib' ConsoleApplication1 C : \Users\Administrator\source\repos\ConsoleApplication1\ConsoleApplication1\LINK 1
boostthat it has a lot of interdependencies. As for the missing library, you didn't copy it to a place on your link path.