From: Timo Heister Date: Sun, 20 Oct 2019 15:24:50 +0000 (+0200) Subject: disable intel system includes X-Git-Tag: v9.2.0-rc1~924^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9ae0d7e24bf6d6a78533ee1b61be5fca0b512949;p=dealii.git disable intel system includes fixes #8374 --- diff --git a/cmake/macros/macro_deal_ii_setup_target.cmake b/cmake/macros/macro_deal_ii_setup_target.cmake index 716c00cdfa..20f300da93 100644 --- a/cmake/macros/macro_deal_ii_setup_target.cmake +++ b/cmake/macros/macro_deal_ii_setup_target.cmake @@ -103,7 +103,15 @@ MACRO(DEAL_II_SETUP_TARGET _target) SET(_build "RELEASE") ENDIF() - TARGET_INCLUDE_DIRECTORIES(${_target} SYSTEM PRIVATE ${DEAL_II_INCLUDE_DIRS}) + IF(CMAKE_CXX_COMPILER_ID MATCHES "Intel") + # Intel (at least up to 19.0.5) confuses an external TBB installation with + # our selected one if we use -Isystem includes. Work around this by using + # normal includes. + # See https://github.com/dealii/dealii/issues/8374 for details. + TARGET_INCLUDE_DIRECTORIES(${_target} PRIVATE ${DEAL_II_INCLUDE_DIRS}) + ELSE() + TARGET_INCLUDE_DIRECTORIES(${_target} SYSTEM PRIVATE ${DEAL_II_INCLUDE_DIRS}) + ENDIF() SET_PROPERTY(TARGET ${_target} APPEND_STRING PROPERTY LINK_FLAGS " ${DEAL_II_LINKER_FLAGS} ${DEAL_II_LINKER_FLAGS_${_build}}"