I am trying to install opencv 3.0.0
on my raspberry pi 2b but I keep running into erros... currently, it complains about the following missing header files when I run the following cmake
command:
cmake -D CMAKE_BUILD_TYPE=RELEASE \
-D CMAKE_INSTALL_PREFIX=/usr/local \
-D INSTALL_C_EXAMPLES=ON \
-D INSTALL_PYTHON_EXAMPLES=ON \
-D OPENCV_EXTRA_MODULES_PATH=~/opencv_contrib-3.0.0/modules \
-D BUILD_EXAMPLES=ON ..
$ cat /home/pi/opencv-3.0.0/build/CMakeFiles/CMakeError.log | grep fatal
/home/pi/opencv-3.0.0/build/CMakeFiles/CMakeTmp/CheckIncludeFile.c:1:10: fatal error: sys/videoio.h: No such file or directory
/home/pi/opencv-3.0.0/build/CMakeFiles/CMakeTmp/CheckIncludeFile.c:1:10: fatal error: ffmpeg/avformat.h: No such file or directory
They do exist in my raspberry pi:
$ locate avformat.h
/home/pi/opencv-3.0.0/3rdparty/include/ffmpeg_/libavformat/avformat.h
/usr/include/arm-linux-gnueabihf/libavformat/avformat.h
$ locate videoio.h
/home/pi/opencv-3.0.0/modules/videoio/include/opencv2/videoio.hpp
/home/pi/opencv-3.0.0/modules/videoio/include/opencv2/videoio/videoio.hpp
/usr/include/sys/videoio.h
I tried to symlink them into /usr/include
under their respective paths, but it didn't work...
Anything I am doing wrong?
Note I am trying to follow this guide for the installation
Edit OS release:
$ cat /etc/os-release
PRETTY_NAME="Raspbian GNU/Linux 10 (buster)"
NAME="Raspbian GNU/Linux"
VERSION_ID="10"
VERSION="10 (buster)"
VERSION_CODENAME=buster
ID=raspbian
ID_LIKE=debian
HOME_URL="http://www.raspbian.org/"
SUPPORT_URL="http://www.raspbian.org/RaspbianForums"
BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs"
10 (buster)
. Added to original question – Tomer Amir Oct 17 '20 at 7:27