Fix when statically linking with distro's boost: in this case, we most likely also need to statically link against icu, as most boost packages are built with it. Without that, you get a bunch of errors at link time (when using boost_locale, or, in freestyle branch, boost_regex).

So when you enable Boost_USE_STATIC_LIBS, you should also set Boost_USE_ICU to True. Will add a note about that in build doc too.
This commit is contained in:
Bastien Montagne
2012-11-19 08:51:35 +00:00
parent 509e178f72
commit 67031c1712
3 changed files with 152 additions and 0 deletions

View File

@@ -644,6 +644,9 @@ if(UNIX AND NOT APPLE)
list(APPEND __boost_packages locale)
endif()
find_package(Boost 1.34 COMPONENTS ${__boost_packages})
if(Boost_USE_STATIC_LIBS AND Boost_USE_ICU)
find_package(IcuLinux)
endif()
mark_as_advanced(Boost_DIR) # why doesnt boost do this?
endif()