mirror of
https://github.com/opencv/opencv.git
synced 2025-06-13 13:13:26 +08:00
minor (unset NPP library variables if not found)
This commit is contained in:
parent
37d39bd9de
commit
b5b00d9ad4
@ -77,16 +77,16 @@ find_library(CUDA_NPP_LIBRARIES
|
|||||||
find_library(CUDA_NPP_LIBRARIES NAMES npp${NPP_SUFFIX} libnpp${NPP_SUFFIX} DOC "NPP library")
|
find_library(CUDA_NPP_LIBRARIES NAMES npp${NPP_SUFFIX} libnpp${NPP_SUFFIX} DOC "NPP library")
|
||||||
mark_as_advanced(CUDA_NPP_LIBRARIES)
|
mark_as_advanced(CUDA_NPP_LIBRARIES)
|
||||||
|
|
||||||
if(NOT EXISTS ${CUDA_NPP_LIBRARIES} OR NOT EXISTS ${CUDA_NPP_INCLUDES}/npp.h)
|
if(NOT EXISTS ${CUDA_NPP_LIBRARIES} OR NOT EXISTS ${CUDA_NPP_INCLUDES}/npp.h)
|
||||||
|
set(CUDA_FOUND FALSE)
|
||||||
|
unset(CUDA_NPP_INCLUDES CACHE)
|
||||||
|
unset(CUDA_NPP_LIBRARIES CACHE)
|
||||||
|
|
||||||
if(NPP_FIND_REQUIRED)
|
if(NPP_FIND_REQUIRED)
|
||||||
message(FATAL_ERROR "NPP headers/libraries are not found. Specify CUDA_NPP_LIBRARY_ROOT_DIR.")
|
message(FATAL_ERROR "NPP headers/libraries are not found. Specify CUDA_NPP_LIBRARY_ROOT_DIR.")
|
||||||
elseif(NOT CUDA_FIND_QUIETLY)
|
elseif(NOT CUDA_FIND_QUIETLY)
|
||||||
message("NPP headers/libraries are not found or CUDA_NPP_LIBRARY_ROOT_DIR not specified.")
|
message("NPP headers/libraries are not found or CUDA_NPP_LIBRARY_ROOT_DIR not specified.")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
set(CUDA_FOUND FALSE)
|
|
||||||
unset(CUDA_NPP_INCLUDES CACHE)
|
|
||||||
unset(CUDA_NPP_LIBRARIES CACHE)
|
|
||||||
else()
|
else()
|
||||||
|
|
||||||
if(APPLE)
|
if(APPLE)
|
||||||
|
Loading…
Reference in New Issue
Block a user