Merge pull request #22816 from cudawarped/remove_windows_cuda_dll_warning

Suppress CUDA nvcc generated warnings #1394-D and #1388-D on windows
This commit is contained in:
Alexander Smorkalov 2022-11-17 09:17:18 +03:00 committed by GitHub
commit 277ead95d9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -421,6 +421,10 @@ if(CUDA_FOUND)
set(CUDA_NVCC_FLAGS ${CUDA_NVCC_FLAGS} -Xcompiler -fno-finite-math-only) set(CUDA_NVCC_FLAGS ${CUDA_NVCC_FLAGS} -Xcompiler -fno-finite-math-only)
endif() endif()
if(WIN32)
set(CUDA_NVCC_FLAGS ${CUDA_NVCC_FLAGS} -Xcudafe --display_error_number --diag-suppress 1394,1388)
endif()
if(CMAKE_CROSSCOMPILING AND (ARM OR AARCH64)) if(CMAKE_CROSSCOMPILING AND (ARM OR AARCH64))
set(CUDA_NVCC_FLAGS ${CUDA_NVCC_FLAGS} -Xlinker --unresolved-symbols=ignore-in-shared-libs) set(CUDA_NVCC_FLAGS ${CUDA_NVCC_FLAGS} -Xlinker --unresolved-symbols=ignore-in-shared-libs)
endif() endif()