[opencv-3.4.0] CMake error: "Configuring incomplete, errors occurred!"

asked 2018-02-25 19:53:57 -0600

roach374 gravatar image

I'm trying to build openCV on Raspberry Pi, following the instructions at https://www.pyimagesearch.com/2017/09... .

After installing all dependencies, I'm running:

cmake -D CMAKE_BUILD_TYPE=RELEASE \
-D CMAKE_INSTALL_PREFIX=/usr/local \
-D INSTALL_C_EXAMPLES=OFF \
-D INSTALL_PYTHON_EXAMPLES=ON \
-D OPENCV_EXTRA_MODULES_PATH=~/opencv_contrib/modules \
-D BUILD_EXAMPLES=ON ..

Which gives me the following output on stdout:

-- Looking for ccache - not found
-- FP16 is not supported by C++ compiler
-- Found ZLIB: /usr/lib/arm-linux-gnueabihf/libz.so (found suitable version "1.2.8", minimum required is "1.2.3") 
-- Found ZLIB: /usr/lib/arm-linux-gnueabihf/libz.so (found version "1.2.8") 
-- Checking for module 'gstreamer-base-1.0'
--   No package 'gstreamer-base-1.0' found
-- Checking for module 'gstreamer-video-1.0'
--   No package 'gstreamer-video-1.0' found
-- Checking for module 'gstreamer-app-1.0'
--   No package 'gstreamer-app-1.0' found
-- Checking for module 'gstreamer-riff-1.0'
--   No package 'gstreamer-riff-1.0' found
-- Checking for module 'gstreamer-pbutils-1.0'
--   No package 'gstreamer-pbutils-1.0' found
-- Checking for module 'gstreamer-base-0.10'
--   No package 'gstreamer-base-0.10' found
-- Checking for module 'gstreamer-video-0.10'
--   No package 'gstreamer-video-0.10' found
-- Checking for module 'gstreamer-app-0.10'
--   No package 'gstreamer-app-0.10' found
-- Checking for module 'gstreamer-riff-0.10'
--   No package 'gstreamer-riff-0.10' found
-- Checking for module 'gstreamer-pbutils-0.10'
--   No package 'gstreamer-pbutils-0.10' found
-- Checking for module 'libdc1394-2'
--   No package 'libdc1394-2' found
-- Checking for module 'libdc1394'
--   No package 'libdc1394' found
-- Looking for linux/videodev.h
-- Looking for linux/videodev.h - not found
-- Looking for linux/videodev2.h
-- Looking for linux/videodev2.h - found
-- Looking for sys/videoio.h
-- Looking for sys/videoio.h - not found
-- Checking for module 'libavresample'
--   No package 'libavresample' found
-- Checking for module 'libgphoto2'
--   No package 'libgphoto2' found
-- Could not find OpenBLAS lib. Turning OpenBLAS_FOUND off
-- Could NOT find Atlas (missing:  Atlas_CLAPACK_INCLUDE_DIR) 
-- A library with BLAS API found.
-- A library with LAPACK API found.
-- Could NOT find Doxygen (missing:  DOXYGEN_EXECUTABLE) 
-- Could NOT find JNI (missing:  JAVA_AWT_LIBRARY JAVA_JVM_LIBRARY JAVA_INCLUDE_PATH JAVA_INCLUDE_PATH2 JAVA_AWT_INCLUDE_PATH) 
-- Could NOT find Pylint (missing:  PYLINT_EXECUTABLE) 
-- Could NOT find Matlab (missing:  MATLAB_MEX_SCRIPT MATLAB_INCLUDE_DIRS MATLAB_ROOT_DIR MATLAB_LIBRARIES MATLAB_LIBRARY_DIRS MATLAB_MEXEXT MATLAB_ARCH MATLAB_BIN) 
-- VTK is not found. Please set -DVTK_DIR in CMake to VTK build directory, or to VTK install subdirectory with VTKConfig.cmake file
CMake Error at cmake/OpenCVModule.cmake:300 (message):
  No extra modules found in folder: /home/pi/opencv_contrib/modules

  Please provide path to 'opencv_contrib/modules' folder.
Call Stack (most recent call first):
  modules/CMakeLists.txt:7 (ocv_glob_modules)


-- Excluding from source files list: /home/pi/opencv-3.4.0/modules/core/src/convert.avx2.cpp
-- Excluding from source files list: /home/pi/opencv-3.4.0/modules/core/src/convert.fp16.cpp
-- Excluding from source files list: /home/pi/opencv-3.4.0/modules/core/src/convert.sse4_1.cpp
-- Excluding from source files list: /home/pi/opencv-3.4.0/build/modules/core/mathfuncs_core.sse2.cpp
-- Excluding from source files list: /home/pi/opencv-3.4.0/build/modules/core/mathfuncs_core.avx.cpp
-- Excluding from source files list: /home/pi/opencv-3.4.0/build/modules/core/mathfuncs_core.avx2.cpp
-- Excluding from source files list: /home/pi/opencv-3.4.0/build/modules/core/stat.sse4_2.cpp
-- Excluding from source files ...
(more)
edit retag flag offensive close merge delete

Comments

there is No extra modules found in folder: /home/pi/opencv_contrib/modules

did you download opencv_ontrib ?

LBerger gravatar imageLBerger ( 2018-02-26 02:17:00 -0600 )edit

Yes, there were all sorts of things wrong with the way I copy/pasted the CMAKE command. Basically all those paths were wrong. I eventually got it working, after taking a step back and using my brain for a second. The command I eventually used was:

cmake -D CMAKE_BUILD_TYPE=RELEASE \ -D CMAKE_INSTALL_PREFIX=/usr/local \ -D INSTALL_PYTHON_EXAMPLES=ON \ -D OPENCV_EXTRA_MODULES_PATH=~/opencv_contrib-3.4.0/modules \ -D BUILD_EXAMPLES=ON ..

roach374 gravatar imageroach374 ( 2018-02-26 11:52:29 -0600 )edit

there is no space between -D an option:

cmake -DCMAKE_BUILD_TYPE=RELEASE

LBerger gravatar imageLBerger ( 2018-02-26 15:50:55 -0600 )edit

I'm having the same issue following these steps: https://www.learnopencv.com/install-o...

Was any solution found?

UPD: Your solution worked. Thanks a lot!

Chput gravatar imageChput ( 2018-04-03 08:35:29 -0600 )edit