diff options
author | Brad King <brad.king@kitware.com> | 2018-05-07 15:26:33 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2018-05-07 15:30:21 (GMT) |
commit | 9a66345752316126783f0bb2b3aa3d51a89e3e50 (patch) | |
tree | 44a46c8ccf78897cb4463070f7c46d5431d97107 /Modules/FindCUDA.cmake | |
parent | fbe6cd1596bf280edd49aeb8f981f99d7cd8beb3 (diff) | |
download | CMake-9a66345752316126783f0bb2b3aa3d51a89e3e50.zip CMake-9a66345752316126783f0bb2b3aa3d51a89e3e50.tar.gz CMake-9a66345752316126783f0bb2b3aa3d51a89e3e50.tar.bz2 |
FindCUDA: Fix regression in separable compilation without cublas
Revert commit v3.11.0-rc1~274^2 (FindCUDA: Add cublas device library to
separable compilation, 2017-11-03). It breaks targets that do not link
to cublas. Another solution will be needed to solve the original
problem in a more compatible way.
Fixes: #17965
Diffstat (limited to 'Modules/FindCUDA.cmake')
-rw-r--r-- | Modules/FindCUDA.cmake | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Modules/FindCUDA.cmake b/Modules/FindCUDA.cmake index 0a31ac2..e3cb4fe 100644 --- a/Modules/FindCUDA.cmake +++ b/Modules/FindCUDA.cmake @@ -1760,7 +1760,7 @@ function(CUDA_LINK_SEPARABLE_COMPILATION_OBJECTS output_file cuda_target options add_custom_command( OUTPUT ${output_file} DEPENDS ${object_files} - COMMAND ${CUDA_NVCC_EXECUTABLE} ${nvcc_flags} -dlink ${object_files} ${CUDA_cublas_device_LIBRARY} -o ${output_file} + COMMAND ${CUDA_NVCC_EXECUTABLE} ${nvcc_flags} -dlink ${object_files} -o ${output_file} ${flags} COMMENT "Building NVCC intermediate link file ${output_file_relative_path}" COMMAND_EXPAND_LISTS @@ -1773,7 +1773,7 @@ function(CUDA_LINK_SEPARABLE_COMPILATION_OBJECTS output_file cuda_target options PRE_LINK COMMAND ${CMAKE_COMMAND} -E echo "Building NVCC intermediate link file ${output_file_relative_path}" COMMAND ${CMAKE_COMMAND} -E make_directory "${output_file_dir}" - COMMAND ${CUDA_NVCC_EXECUTABLE} ${nvcc_flags} ${flags} -dlink ${object_files} ${CUDA_cublas_device_LIBRARY} -o "${output_file}" + COMMAND ${CUDA_NVCC_EXECUTABLE} ${nvcc_flags} ${flags} -dlink ${object_files} -o "${output_file}" COMMAND_EXPAND_LISTS ${_verbatim} ) |