diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 6037c67c22c61e8c9d7895be5a417c767ec3c5f2..9b713f7ca7e736dc5a17d3d953eb1148cbecabbd 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -20,7 +20,7 @@ SET( CMAKE_BUILD_TYPE Release) INCLUDE (${PROJECT_SOURCE_DIR}/FindmvIMPACT.cmake) #find the cv support and set HAVE_OPENCV_H for the conditional compilation -FIND_PACKAGE(OpenCV 3) +FIND_PACKAGE(OpenCV 3.1) if (OpenCV_FOUND) if (${OpenCV_VERSION_MAJOR} GREATER 2) diff --git a/src/examples/CMakeLists.txt b/src/examples/CMakeLists.txt index f0b40b2d7370be87c8612bf895adfaac951536f1..6b7ae2f2a0d006b670bc7a73e06a8da2e9f9713f 100644 --- a/src/examples/CMakeLists.txt +++ b/src/examples/CMakeLists.txt @@ -1,8 +1,17 @@ # add the necessary include directories INCLUDE_DIRECTORIES(.) -# create an example application -ADD_EXECUTABLE(mvbluefox3_test mvbluefox3_test.cpp) +if (USE_CV) + + # create an example application + ADD_EXECUTABLE(mvbluefox3_test mvbluefox3_test.cpp) + + # link necessary libraries + TARGET_LINK_LIBRARIES(mvbluefox3_test mvbluefox3 ${mvIMPACT_LIBRARY} ${OpenCV_LIBS}) + +endif() + + + + -# link necessary libraries -TARGET_LINK_LIBRARIES(mvbluefox3_test mvbluefox3)