X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=CMakeLists.txt;h=b42534f39ed860bc413df4e7d690f9108022217d;hp=a27d1a6fd21edfec175b7b252cf2cbc89f95be24;hb=063f4bce9c3c3d6e4efe68c0e95d95213ad08f52;hpb=07c41b7cebcc87a313a5bfccd50a7949d126180a diff --git a/CMakeLists.txt b/CMakeLists.txt index a27d1a6f..b42534f3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -330,11 +330,19 @@ endif() # Non-Qt-based packages ##################################################################### -find_package(Boost 1.56 REQUIRED) +find_package(Boost 1.54 REQUIRED) set_package_properties(Boost PROPERTIES TYPE REQUIRED URL "https://www.boost.org/" DESCRIPTION "Boost libraries for C++" ) +# Older versions don't define the imported target +if (NOT TARGET Boost::boost) + add_library(Boost::boost INTERFACE IMPORTED GLOBAL) + if (Boost_INCLUDE_DIRS) + set_target_properties(Boost::boost PROPERTIES + INTERFACE_INCLUDE_DIRECTORIES "${Boost_INCLUDE_DIRS}") + endif() +endif() find_package(ZLIB REQUIRED) set_package_properties(ZLIB PROPERTIES TYPE REQUIRED @@ -352,6 +360,12 @@ if (NOT WIN32) ) endif() +# Shared library support +##################################################################### + +option(ENABLE_SHARED "Build modules as shared libraries" ON) +add_feature_info(ENABLE_SHARED ENABLE_SHARED "Build modules as shared libraries") + # Setup unit testing #####################################################################