File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -32,9 +32,9 @@ endfunction()
3232# Function to check if a path is valid
3333function (path_ok result inPath)
3434 if (EXISTS "${inPath} " AND IS_DIRECTORY "${inPath} " )
35- set (${result} TRUE )
35+ set (${result} TRUE PARENT_SCOPE )
3636 else ()
37- set (${result} FALSE )
37+ set (${result} FALSE PARENT_SCOPE )
3838 endif ()
3939endfunction ()
4040
@@ -55,13 +55,15 @@ if(DEFINED ENV{${BEST_CUDA_ENVVAR}})
5555 set (cuda_path $ENV{${BEST_CUDA_ENVVAR} })
5656endif ()
5757
58+ # if not found in envvar, try if path exist ( linux )
5859if (NOT cuda_path)
5960 path_ok(cuda_path_ok ${BEST_CUDA_PATH_LINUX} )
6061 if (cuda_path_ok)
6162 set (cuda_path ${BEST_CUDA_PATH_LINUX} )
6263 endif ()
6364endif ()
6465
66+ # try the windows path
6567if (NOT cuda_path)
6668 path_ok(cuda_path_ok ${BEST_CUDA_PATH_WINDOWS} )
6769 if (cuda_path_ok)
You can’t perform that action at this time.
0 commit comments