mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-20 12:54:11 +08:00
[1/N] Don't use CUDA.cmake module (#157188)
Small changes before removing CUDA.cmake. Pull Request resolved: https://github.com/pytorch/pytorch/pull/157188 Approved by: https://github.com/ezyang
This commit is contained in:
@ -3,7 +3,7 @@
|
||||
# CUB_INCLUDE_DIRS - the CUB include directory
|
||||
|
||||
find_path(CUB_INCLUDE_DIR
|
||||
HINTS "${CUDA_TOOLKIT_INCLUDE}"
|
||||
HINTS "${CUDAToolkit_INCLUDE_DIRS}"
|
||||
NAMES cub/cub.cuh
|
||||
DOC "The directory where CUB includes reside"
|
||||
)
|
||||
|
@ -478,6 +478,11 @@ else()
|
||||
set(TORCH_VERSION_DEBUG 0)
|
||||
endif()
|
||||
|
||||
set(CUDA_VERSION "")
|
||||
if(CUDAToolkit_VERSION_MAJOR)
|
||||
set(CUDA_VERSION "${CUDAToolkit_VERSION_MAJOR}.${CUDAToolkit_VERSION_MINOR}")
|
||||
endif()
|
||||
|
||||
add_custom_target(
|
||||
gen_torch_version ALL
|
||||
"${Python_EXECUTABLE}" "${TOOLS_PATH}/generate_torch_version.py"
|
||||
|
Reference in New Issue
Block a user