Merge pull request #2488 from blattms/fix-cuda-version-check

Fix CUDA version check to allow versions 9.0 or newer.
This commit is contained in:
Markus Blatt 2020-03-23 09:45:20 +01:00 committed by GitHub
commit 53d636a3b1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -47,7 +47,12 @@ if(NOT CMAKE_DISABLE_FIND_PACKAGE_CUDA AND
# only easy way to determine the cublas and cusparse libraries.
# Hence we call it unconditionally
# The WellContributions kernel uses __shfl_down_sync, which was introduced in CUDA 9.0
find_package(CUDA 9.0)
find_package(CUDA)
if(CUDA_VERSION VERSION_LESS "9.7")
set(CUDA_FOUND OFF)
message(WARNING "Deactivating CUDA as we require version 9.0 or newer."
" Found only CUDA version ${CUDA_VERSION}.")
endif()
endif()
if(CUDA_FOUND)