From: Karl Ljungkvist Date: Wed, 18 May 2016 16:21:10 +0000 (-0500) Subject: Move check for C++11 inside if case to not affect non-cuda configuration X-Git-Tag: v8.5.0-rc1~1029^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F2616%2Fhead;p=dealii.git Move check for C++11 inside if case to not affect non-cuda configuration --- diff --git a/cmake/configure/configure_1_cuda.cmake b/cmake/configure/configure_1_cuda.cmake index e372b709bc..4d16b2fbfe 100644 --- a/cmake/configure/configure_1_cuda.cmake +++ b/cmake/configure/configure_1_cuda.cmake @@ -19,15 +19,17 @@ MACRO(FEATURE_CUDA_FIND_EXTERNAL var) - IF(NOT DEAL_II_WITH_CXX11) - MESSAGE(FATAL_ERROR "\n" - "CUDA only supported with C++11. Reconfigure with DEAL_II_WITH_CXX11=ON.\n" - ) - ENDIF() FIND_PACKAGE(CUDA) IF(CUDA_FOUND) + + IF(NOT DEAL_II_WITH_CXX11) + MESSAGE(FATAL_ERROR "\n" + "CUDA only supported with C++11. Reconfigure with DEAL_II_WITH_CXX11=ON.\n" + ) + ENDIF() + SET(CUDA_ATTACH_VS_BUILD_RULE_TO_CUDA_FILE FALSE) # Activate C++11 since we require it above.