0

I am getting the following errors after doing running 'make' command.

[  0%] Building CXX object modules/core/CMakeFiles/opencv_core.dir/src/matmul.o
c++: error: -pg and -fomit-frame-pointer are incompatible
make[2]: *** [modules/core/CMakeFiles/opencv_core.dir/src/matmul.o] Error 1
make[1]: *** [modules/core/CMakeFiles/opencv_core.dir/all] Error 2
make: *** [all] Error 2

I am following the tutorial on http://mitchtech.net/raspberry-pi-opencv/ link.

Following were missing when i did cmake before doing make:

cmake -D CMAKE_BUILD_TYPE=RELEASE -D CMAKE_INSTALL_PREFIX=/usr/local -D BUILD_PYTHON_SUPPORT=ON -D BUILD_EXAMPLES=ON ..
-- Detected version of GNU GCC: 46 (406)
-- checking for module 'gstreamer-app-0.10'
--   package 'gstreamer-app-0.10' not found
-- checking for module 'gstreamer-video-0.10'
--   package 'gstreamer-video-0.10' not found
-- checking for module 'libswscale'
--   package 'libswscale' not found
-- Could NOT find Jasper (missing:  JASPER_LIBRARIES JASPER_INCLUDE_DIR) 
--     Use NumPy headers from: /usr/lib/pymodules/python2.7/numpy/core/include
Traceback (most recent call last):
  File "<string>", line 1, in <module>
ImportError: No module named sphinx
CUDA_TOOLKIT_ROOT_DIR not found or specified
-- Could NOT find CUDA (missing:  CUDA_TOOLKIT_ROOT_DIR CUDA_NVCC_EXECUTABLE CUDA_INCLUDE_DIRS CUDA_CUDART_LIBRARY) (Required is at least version "4.0")
-- Parsing 'cvconfig.h.cmake'

Can somebody please explain what is happening and what is the solution to it ? I am new to both OpenCV and R-Pi.

3
  • I'm guessing your missing 'Jasper' and 'sphinx' packages/modules? Commented Feb 20, 2014 at 15:50
  • You have apparently configured your OpenCV build to use/include CUDA (and you haven't installed it), I don't think you want to do that in a R-Pi environment. Did you use the exact OpenCV version indicated in that tutorial? (ie. wget http://sourceforge.net/projects/opencvlibrary/files/opencv-unix/2.3.1/OpenCV-2.3.1a.tar.bz2 ) Commented Feb 20, 2014 at 16:09
  • Yes I am using the exact OpenCV version and following the link as it is. Commented Feb 21, 2014 at 4:12

1 Answer 1

1

Following the link you refer "as is" will have solved the issue.

Some essential packages are missing and hence the error.

Install by entering the following commands before compiling OpenCV. You must have an active net connection!

sudo apt-get -y install build-essential cmake cmake-qt-gui pkg-config libpng12-0 libpng12-dev libpng++-dev libpng3 libpnglite-dev zlib1g-dbg zlib1g zlib1g-dev pngtools libtiff4-dev libtiff4 libtiffxx0c2 libtiff-tools

sudo apt-get -y install libjpeg8 libjpeg8-dev libjpeg8-dbg libjpeg-progs ffmpeg libavcodec-dev libavcodec53 libavformat53 libavformat-dev libgstreamer0.10-0-dbg libgstreamer0.10-0 libgstreamer0.10-dev libxine1-ffmpeg libxine-dev libxine1-bin libunicap2 libunicap2-dev libdc1394-22-dev libdc1394-22 libdc1394-utils swig libv4l-0 libv4l-dev python-numpy libpython2.6 python-dev python2.6-dev libgtk2.0-dev pkg-config

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.