diff options
author | Boris Fomitchev <bfomitchev@nvidia.com> | 2016-04-19 22:13:51 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2016-06-09 13:24:40 (GMT) |
commit | e9bfe8da04c5486335d15c68b544f25f940c9c92 (patch) | |
tree | f519f4a9661520607c21c2e6ad6b34f0b54007ee /Modules | |
parent | 8f3bd1f454fe50a641fd9666ca5e5bc8064c09c7 (diff) | |
download | CMake-e9bfe8da04c5486335d15c68b544f25f940c9c92.zip CMake-e9bfe8da04c5486335d15c68b544f25f940c9c92.tar.gz CMake-e9bfe8da04c5486335d15c68b544f25f940c9c92.tar.bz2 |
FindCUDA: Adjust vertical whitespace
Diffstat (limited to 'Modules')
-rw-r--r-- | Modules/FindCUDA.cmake | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/Modules/FindCUDA.cmake b/Modules/FindCUDA.cmake index 48bb554..b111050 100644 --- a/Modules/FindCUDA.cmake +++ b/Modules/FindCUDA.cmake @@ -188,10 +188,8 @@ # files. # # -# # CUDA_LINK_SEPARABLE_COMPILATION_OBJECTS( output_file_var cuda_target # nvcc_flags object_files) -# # -- Generates the link object required by separable compilation from the given # object files. This is called automatically for CUDA_ADD_EXECUTABLE and # CUDA_ADD_LIBRARY, but can be called manually when using CUDA_WRAP_SRCS @@ -563,7 +561,6 @@ macro(cuda_unset_include_and_libraries) unset(CUDA_npps_LIBRARY CACHE) unset(CUDA_nvcuvenc_LIBRARY CACHE) unset(CUDA_nvcuvid_LIBRARY CACHE) - unset(CUDA_USE_STATIC_CUDA_RUNTIME CACHE) endmacro() @@ -601,6 +598,7 @@ if(NOT CUDA_TOOLKIT_ROOT_DIR) DOC "Toolkit location." NO_DEFAULT_PATH ) + # Now search default paths find_path(CUDA_TOOLKIT_ROOT_DIR NAMES nvcc nvcc.exe @@ -614,6 +612,7 @@ if(NOT CUDA_TOOLKIT_ROOT_DIR) # We need to force this back into the cache. set(CUDA_TOOLKIT_ROOT_DIR ${CUDA_TOOLKIT_ROOT_DIR} CACHE PATH "Toolkit location." FORCE) endif() + if (NOT EXISTS ${CUDA_TOOLKIT_ROOT_DIR}) if(CUDA_FIND_REQUIRED) message(FATAL_ERROR "Specify CUDA_TOOLKIT_ROOT_DIR") @@ -742,6 +741,8 @@ if(NOT CUDA_VERSION VERSION_LESS "5.5") cuda_find_library_local_first(CUDA_cudart_static_LIBRARY cudart_static "static CUDA runtime library") mark_as_advanced(CUDA_cudart_static_LIBRARY) endif() + + if(CUDA_cudart_static_LIBRARY) # Set whether to use the static cuda runtime. option(CUDA_USE_STATIC_CUDA_RUNTIME "Use the static version of the CUDA runtime library if available" ON) @@ -955,6 +956,7 @@ set(CUDA_SDK_ROOT_DIR_INTERNAL "${CUDA_SDK_ROOT_DIR}" CACHE INTERNAL "This is the value of the last time CUDA_SDK_ROOT_DIR was set successfully." FORCE) include(${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake) + find_package_handle_standard_args(CUDA REQUIRED_VARS CUDA_TOOLKIT_ROOT_DIR |