From 63397e825c965f71162d49233fc940bc15205d61 Mon Sep 17 00:00:00 2001 From: Andrey Kamaev Date: Sat, 20 Oct 2012 16:37:46 +0400 Subject: [PATCH] Cleanup CMakeLists.txt of ocl module --- modules/ocl/CMakeLists.txt | 18 +++++++----------- modules/ocl/src/precomp.hpp | 10 ++++------ 2 files changed, 11 insertions(+), 17 deletions(-) diff --git a/modules/ocl/CMakeLists.txt b/modules/ocl/CMakeLists.txt index 00d35ba9f..5cbf57cbc 100644 --- a/modules/ocl/CMakeLists.txt +++ b/modules/ocl/CMakeLists.txt @@ -4,7 +4,7 @@ if(NOT HAVE_OPENCL) endif() set(the_description "OpenCL-accelerated Computer Vision") -ocv_add_module(ocl opencv_core opencv_imgproc opencv_calib3d opencv_objdetect opencv_video opencv_nonfree opencv_ts) +ocv_add_module(ocl opencv_core opencv_imgproc opencv_features2d opencv_objdetect opencv_video) ocv_module_include_directories() @@ -27,7 +27,7 @@ source_group("Src\\Host" FILES ${lib_srcs} ${lib_int_hdrs} ${kernels_cpp}) if (HAVE_OPENCL) set(ocl_link_libs ${OPENCL_LIBRARIES}) if(OPENCL_INCLUDE_DIR) - ocv_include_directories(${OPENCL_INCLUDE_DIR}) + ocv_include_directories(${OPENCL_INCLUDE_DIR}) endif() if (HAVE_CLAMDFFT) set(ocl_link_libs ${ocl_link_libs} ${CLAMDFFT_LIBRARIES}) @@ -39,17 +39,12 @@ if (HAVE_OPENCL) endif() endif() -ocv_set_module_sources( - HEADERS ${lib_hdrs} - SOURCES ${lib_int_hdrs} ${lib_srcs} - ) - -set(OPENCV_MODULE_opencv_ocl_SOURCES ${OPENCV_MODULE_opencv_ocl_SOURCES} ${kernels_cpp}) +ocv_set_module_sources(HEADERS ${lib_hdrs} SOURCES ${lib_int_hdrs} ${lib_srcs} ${kernels_cpp}) ocv_create_module(${ocl_link_libs}) install(FILES ${lib_hdrs} - DESTINATION include/opencv2/${name} - COMPONENT main) + DESTINATION include/opencv2/${name} + COMPONENT main) ocv_add_precompiled_headers(${the_module}) @@ -61,6 +56,7 @@ file(GLOB test_hdrs "test/*.hpp" "test/*.h") ocv_add_accuracy_tests(FILES "Include" ${test_hdrs} FILES "Src" ${test_srcs}) + ################################################################################################################ ################################ OpenCL Module Performance ################################################## ################################################################################################################ @@ -68,4 +64,4 @@ file(GLOB perf_srcs "perf/*.cpp") file(GLOB perf_hdrs "perf/*.hpp" "perf/*.h") ocv_add_perf_tests(FILES "Include" ${perf_hdrs} - FILES "Src" ${perf_srcs}) + FILES "Src" ${perf_srcs}) diff --git a/modules/ocl/src/precomp.hpp b/modules/ocl/src/precomp.hpp index 33f89dffc..41b488ad4 100644 --- a/modules/ocl/src/precomp.hpp +++ b/modules/ocl/src/precomp.hpp @@ -63,16 +63,14 @@ #include #include -#include "opencv2/ocl/ocl.hpp" - -#include "opencv2/imgproc/imgproc.hpp" - -#include "opencv2/objdetect/objdetect.hpp" #include "opencv2/imgproc/imgproc.hpp" #include "opencv2/imgproc/imgproc_c.h" #include "opencv2/core/core_c.h" -//#include "opencv2/highgui/highgui.hpp" +#include "opencv2/objdetect/objdetect.hpp" +#include "opencv2/ocl/ocl.hpp" + #include "opencv2/core/internal.hpp" +//#include "opencv2/highgui/highgui.hpp" #define __ATI__