Skip to content

Commit 4b7c0b9

Browse files
committed
cuda: fix samples
1 parent 68e5066 commit 4b7c0b9

File tree

2 files changed

+4
-12
lines changed

2 files changed

+4
-12
lines changed

samples/gpu/CMakeLists.txt

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -14,27 +14,19 @@ if(BUILD_EXAMPLES AND OCV_DEPENDENCIES_FOUND)
1414
project("${project}_samples")
1515

1616
ocv_include_modules_recurse(${OPENCV_CUDA_SAMPLES_REQUIRED_DEPS})
17-
ocv_include_directories(
18-
"${OpenCV_SOURCE_DIR}/modules/gpu/src/nvidia"
19-
"${OpenCV_SOURCE_DIR}/modules/gpu/src/nvidia/core"
20-
)
2117

2218
if(HAVE_opencv_xfeatures2d)
23-
ocv_include_directories("${OpenCV_SOURCE_DIR}/modules/xfeatures2d/include")
19+
ocv_include_modules_recurse(opencv_xfeatures2d)
2420
endif()
2521

2622
if(HAVE_opencv_cudacodec)
27-
ocv_include_directories("${OpenCV_SOURCE_DIR}/modules/cudacodec/include")
23+
ocv_include_modules_recurse(opencv_cudacodec)
2824
endif()
2925

3026
if(HAVE_CUDA)
3127
ocv_include_directories(${CUDA_INCLUDE_DIRS})
3228
endif()
3329

34-
if(HAVE_OPENCL)
35-
ocv_include_directories("${OpenCV_SOURCE_DIR}/modules/ocl/include")
36-
endif()
37-
3830
if(CMAKE_COMPILER_IS_GNUCXX AND NOT ENABLE_NOISY_WARNINGS)
3931
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-function")
4032
endif()

samples/gpu/performance/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@ file(GLOB sources "performance/*.cpp")
44
file(GLOB headers "performance/*.h")
55

66
if(HAVE_opencv_xfeatures2d)
7-
ocv_include_directories("${opencv_xfeatures2d_SOURCE_DIR}/include")
7+
ocv_include_modules_recurse(opencv_xfeatures2d)
88
endif()
99

1010
if(HAVE_opencv_bgsegm)
11-
ocv_include_directories("${opencv_bgsegm_SOURCE_DIR}/include")
11+
ocv_include_modules_recurse(opencv_bgsegm)
1212
endif()
1313

1414
add_executable(${the_target} ${sources} ${headers})

0 commit comments

Comments
 (0)