summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--cmake/opentrack-platform.cmake2
-rw-r--r--cv/CMakeLists.txt2
-rw-r--r--tracker-aruco/CMakeLists.txt2
-rw-r--r--tracker-ht/CMakeLists.txt2
-rw-r--r--tracker-pt/CMakeLists.txt2
5 files changed, 6 insertions, 4 deletions
diff --git a/cmake/opentrack-platform.cmake b/cmake/opentrack-platform.cmake
index e112e86a..567ba0cb 100644
--- a/cmake/opentrack-platform.cmake
+++ b/cmake/opentrack-platform.cmake
@@ -68,3 +68,5 @@ endif()
if(MINGW)
add_definitions(-DMINGW_HAS_SECURE_API)
endif()
+
+set(opencv-modules opencv_calib3d opencv_core opencv_features2d opencv_imgcodecs opencv_imgproc opencv_objdetect opencv_video opencv_videoio)
diff --git a/cv/CMakeLists.txt b/cv/CMakeLists.txt
index 0f29c4f2..6a1a18b4 100644
--- a/cv/CMakeLists.txt
+++ b/cv/CMakeLists.txt
@@ -1,4 +1,4 @@
-find_package(OpenCV 3.0 QUIET)
+find_package(OpenCV 3.0 QUIET COMPONENTS ${opencv-modules})
if(OpenCV_FOUND)
opentrack_boilerplate(opentrack-cv STATIC)
target_link_libraries(opentrack-cv ${OpenCV_LIBS})
diff --git a/tracker-aruco/CMakeLists.txt b/tracker-aruco/CMakeLists.txt
index c6f8f275..8f3e9e7c 100644
--- a/tracker-aruco/CMakeLists.txt
+++ b/tracker-aruco/CMakeLists.txt
@@ -1,4 +1,4 @@
-find_package(OpenCV 3.0 QUIET)
+find_package(OpenCV 3.0 QUIET COMPONENTS ${opencv-modules})
set(SDK_ARUCO_LIBPATH "" CACHE FILEPATH "Aruco paper marker tracker static library path")
if(SDK_ARUCO_LIBPATH)
opentrack_boilerplate(opentrack-tracker-aruco)
diff --git a/tracker-ht/CMakeLists.txt b/tracker-ht/CMakeLists.txt
index 82784fe6..06791993 100644
--- a/tracker-ht/CMakeLists.txt
+++ b/tracker-ht/CMakeLists.txt
@@ -1,7 +1,7 @@
if(FALSE)
set(SDK_HT "" CACHE FILEPATH "Path to headtracker library")
set(SDK_HT_FLANDMARK "" CACHE FILEPATH "Path to flandmark library for headtracker")
-find_package(OpenCV 3.0 QUIET)
+find_package(OpenCV 3.0 QUIET COMPONENTS ${opencv-modules})
if(OpenCV_FOUND)
if(SDK_HT AND SDK_HT_FLANDMARK)
opentrack_boilerplate(opentrack-tracker-ht)
diff --git a/tracker-pt/CMakeLists.txt b/tracker-pt/CMakeLists.txt
index b2539a74..27652eaa 100644
--- a/tracker-pt/CMakeLists.txt
+++ b/tracker-pt/CMakeLists.txt
@@ -1,4 +1,4 @@
-find_package(OpenCV 3.0 QUIET)
+find_package(OpenCV 3.0 QUIET COMPONENTS ${opencv-modules})
if(OpenCV_FOUND)
opentrack_boilerplate(opentrack-tracker-pt)
target_link_libraries(opentrack-tracker-pt opentrack-cv ${OpenCV_LIBS})