From: Matthias Maier Date: Mon, 11 Jul 2016 09:33:40 +0000 (-0500) Subject: CMake: Add a guard around FIND_SYSTEM_LIBRARY for windows X-Git-Tag: v8.5.0-rc1~890^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F2801%2Fhead;p=dealii.git CMake: Add a guard around FIND_SYSTEM_LIBRARY for windows On Windows targets the rt library is not available and somehow we pick it up. Thus, guard the whole configuration. Closes #2397 --- diff --git a/cmake/configure/configure_boost.cmake b/cmake/configure/configure_boost.cmake index a097da7944..1ffbd701a7 100644 --- a/cmake/configure/configure_boost.cmake +++ b/cmake/configure/configure_boost.cmake @@ -26,10 +26,12 @@ MACRO(FEATURE_BOOST_CONFIGURE_BUNDLED) # # Add rt to the link interface as well, boost/chrono needs it. # - FIND_SYSTEM_LIBRARY(rt_LIBRARY NAMES rt) - MARK_AS_ADVANCED(rt_LIBRARY) - IF(NOT rt_LIBRARY MATCHES "-NOTFOUND") - SET(BOOST_LIBRARIES ${rt_LIBRARY}) + IF(NOT CMAKE_SYSTEM_NAME MATCHES "Windows") + FIND_SYSTEM_LIBRARY(rt_LIBRARY NAMES rt) + MARK_AS_ADVANCED(rt_LIBRARY) + IF(NOT rt_LIBRARY MATCHES "-NOTFOUND") + SET(BOOST_LIBRARIES ${rt_LIBRARY}) + ENDIF() ENDIF() ENABLE_IF_SUPPORTED(BOOST_CXX_FLAGS "-Wno-unused-local-typedefs")