FindBoost: Incorrect dependency relation of log/log_setup
In FindBoost.cmake, log_setup
is incorrectly set as a dependency of log
:
set(_Boost_LOG_DEPENDENCIES date_time log_setup filesystem thread regex chrono atomic)
Actually, it's the opposite: log_setup
depends on log
, and log
does not depend on log_setup
.
Currently this issue will cause CMake to put libboost_log.a
before libboost_log_setup.a
in linker's arguments, and will trigger a linker error with gcc.
Looks like CMake will automatically reorder dependencies even if I explicitly write target_link_libraries(${TARGET} Boost::log_setup Boost::log)
, so currently I can't compile my project using gcc...
Edited by Brad King