From ddfd8f60a1492d7ab9663d49ccc1285a8bf8390a Mon Sep 17 00:00:00 2001 From: risemeup1 <62429225+risemeup1@users.noreply.github.com> Date: Thu, 9 Mar 2023 11:04:24 +0800 Subject: [PATCH] fix_ninja_error (#50067) --- cmake/experiments/cuda_module_loading_lazy.cmake | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/cmake/experiments/cuda_module_loading_lazy.cmake b/cmake/experiments/cuda_module_loading_lazy.cmake index a13af61af65..f6da0771be0 100644 --- a/cmake/experiments/cuda_module_loading_lazy.cmake +++ b/cmake/experiments/cuda_module_loading_lazy.cmake @@ -45,6 +45,9 @@ if(LINUX) CACHE BOOL "" FORCE) set(CMAKE_CUDA_FLAGS "--cudart shared") enable_language(CUDA) + set(CMAKE_CUDA_COMPILER + "${CMAKE_SOURCE_DIR}/tools/nvcc_lazy" + CACHE FILEPATH "" FORCE) execute_process( COMMAND "rm" "-rf" "${CMAKE_SOURCE_DIR}/tools/nvcc_lazy" COMMAND "chmod" "755" "${CMAKE_SOURCE_DIR}/tools/nvcc_lazy.sh" @@ -54,7 +57,4 @@ if(LINUX) set(CUDA_NVCC_EXECUTABLE "${CMAKE_SOURCE_DIR}/tools/nvcc_lazy" CACHE FILEPATH "" FORCE) - set(CMAKE_CUDA_COMPILER - "${CMAKE_SOURCE_DIR}/tools/nvcc_lazy" - CACHE FILEPATH "" FORCE) endif() -- GitLab