CMAKE Error in OpenCV 3.0.0 while compiling opencv_contrib

asked 2015-03-26 13:09:18 -0600

kkpant75 gravatar image

my cmake flag list is below along with

cmake -D CMAKE_BUILD_TYPE=RELEASE -D CMAKE_INSTALL_PREFIX=/usr/local -D WITH_TBB=ON -D BUILD_NEW_PYTHON_SUPPORT=ON -D WITH_V4L=ON -D INSTALL_C_EXAMPLES=ON -D INSTALL_PYTHON_EXAMPLES=ON -D BUILD_EXAMPLES=ON -D WITH_QT=ON -D WITH_OPENGL=ON -D WITH_IPP=OFF -D OPENCV_EXTRA_MODULES_PATH=../opencv_contrib ..

-----------------Below Error----------- CMake Error at cmake/OpenCVModule.cmake:949 (install): install FILES given directory "/home/hduser/OpenCV/opencv-3.0.0-alpha/opencv_contrib/modules/bioinspired/samples/ocl" to install. Call Stack (most recent call first): cmake/OpenCVModule.cmake:753 (ocv_add_samples) opencv_contrib/modules/bioinspired/CMakeLists.txt:3 (ocv_define_module)

CMake Error at cmake/OpenCVModule.cmake:949 (install): install FILES given directory "/home/hduser/OpenCV/opencv-3.0.0-alpha/opencv_contrib/modules/face/samples/etc" to install. Call Stack (most recent call first): cmake/OpenCVModule.cmake:753 (ocv_add_samples) opencv_contrib/modules/face/CMakeLists.txt:2 (ocv_define_module)

CMake Error at cmake/OpenCVModule.cmake:949 (install): install FILES given directory "/home/hduser/OpenCV/opencv-3.0.0-alpha/opencv_contrib/modules/saliency/samples/ObjectnessTrainedModel" to install. Call Stack (most recent call first): cmake/OpenCVModule.cmake:753 (ocv_add_samples) opencv_contrib/modules/saliency/CMakeLists.txt:3 (ocv_define_module)

CMake Error at cmake/OpenCVModule.cmake:949 (install): install FILES given directory "/home/hduser/OpenCV/opencv-3.0.0-alpha/opencv_contrib/modules/surface_matching/samples/data" to install. Call Stack (most recent call first): cmake/OpenCVModule.cmake:753 (ocv_add_samples) opencv_contrib/modules/surface_matching/CMakeLists.txt:2 (ocv_define_module)

edit retag flag offensive close merge delete

Comments

1

Please, try to put opencv_contrib outside of opencv. It is better to use out-of-source build scheme:

build/
opencv/
opencv_contrib/

Also, you should pass path to opencv_contrib/modules to cmake:

cmake ../opencv -DOPENCV_EXTRA_MODULES_PATH=../opencv_contrib/modules

Last note: you should use corresponding version of opencv_contrib when building opencv. If you want to build an alpha version, please, checkout the opencv_contrib repository to nearest date since it has no tags yet. I'd recommend you to build latest master branch revisions from github.

mshabunin gravatar imagemshabunin ( 2015-03-27 05:06:19 -0600 )edit

Hi,

please, did you find a solution for this problem ?! i have the same problem !

AshemH gravatar imageAshemH ( 2018-04-14 05:39:51 -0600 )edit