Commit 8832b695 authored by Brad King's avatar Brad King Committed by Kitware Robot
Browse files

Merge topic 'cuda_11'

046e454f CUDA: Error if can't determine toolkit library root

 CUDA: Clang CUDA 11.1 support
Acked-by: Kitware Robot's avatarKitware Robot <>
Merge-request: !5525
parents 9ce530ea 046e454f
......@@ -346,3 +346,5 @@ Changes made since CMake 3.19.0 include the following.
it can break projects that were using the property only to
cause the specified language's compiler to be used. This has
been reverted to restore behavior from CMake 3.18 and below.
* CUDA 11.1 support for Clang.
......@@ -176,13 +176,15 @@ if(NOT CMAKE_CUDA_COMPILER_ID_RUN)
# In a non-scattered installation the following are equivalent to CMAKE_CUDA_COMPILER_TOOLKIT_ROOT.
# We first check for a non-scattered installation to prefer it over a scattered installation.
# CMAKE_CUDA_COMPILER_LIBRARY_ROOT contains the device library and version file.
# CMAKE_CUDA_COMPILER_LIBRARY_ROOT contains the device library.
elseif(CMAKE_SYSROOT_LINK AND EXISTS "${CMAKE_SYSROOT_LINK}/usr/lib/cuda/version.txt")
elseif(CMAKE_SYSROOT_LINK AND EXISTS "${CMAKE_SYSROOT_LINK}/usr/lib/cuda/nvvm/libdevice")
elseif(EXISTS "${CMAKE_SYSROOT}/usr/lib/cuda/version.txt")
elseif(EXISTS "${CMAKE_SYSROOT}/usr/lib/cuda/nvvm/libdevice")
message(FATAL_ERROR "Couldn't find CUDA library root.")
# CMAKE_CUDA_COMPILER_TOOLKIT_LIBRARY_ROOT contains the linking stubs necessary for device linking and other low-level library files.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment