From 1d6c34366112f66b2d263c2aab587ddfa6ee85ae Mon Sep 17 00:00:00 2001 From: Robert Maynard Date: Thu, 20 Apr 2023 17:08:38 -0400 Subject: FindCUDAToolkit: Add missing static library dependencies on pthread and libdl Discourse-topic: https://discourse.cmake.org/t/7946 --- Modules/FindCUDAToolkit.cmake | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Modules/FindCUDAToolkit.cmake b/Modules/FindCUDAToolkit.cmake index fcafe65..ace7db1 100644 --- a/Modules/FindCUDAToolkit.cmake +++ b/Modules/FindCUDAToolkit.cmake @@ -1028,7 +1028,11 @@ if(CUDAToolkit_FOUND) endif() _CUDAToolkit_find_and_add_import_lib(culibos) # it's a static library - foreach (cuda_lib cublasLt cufft curand nppc nvjpeg) + foreach (cuda_lib cublasLt cufft nvjpeg) + _CUDAToolkit_find_and_add_import_lib(${cuda_lib}) + _CUDAToolkit_find_and_add_import_lib(${cuda_lib}_static DEPS cudart_static_deps culibos) + endforeach() + foreach (cuda_lib curand nppc) _CUDAToolkit_find_and_add_import_lib(${cuda_lib}) _CUDAToolkit_find_and_add_import_lib(${cuda_lib}_static DEPS culibos) endforeach() -- cgit v0.12