我使用Elementary OS,并尝试安装OpenCV 3.1.0,请按照http://docs.opencv.org/3.0-beta/doc/tutorials/introduction/linux_install/linux_install.html的说明进行操作
另外,我已经安装了libav 11.7和ffmpeg 3.1.3
但是,在cmake -D CMAKE_BUILD_TYPE = RELEASE之后-D CMAKE_INSTALL_PREFIX =/usr/local ..
我得到:
-寻找linux/videodev.h
-寻找linux/videodev.h-找到
-寻找linux/videodev2.h
-寻找linux/videodev2.h-找到
-寻找sys/videoio.h
-寻找sys/videoio.h-找不到
-寻找libavformat/avformat.h
-寻找libavformat/avformat.h-找到
-寻找ffmpeg/avformat.h
-寻找ffmpeg/avformat.h-找不到
-检查模块'libgphoto2'
-找不到包'libgphoto2'
然后制作
我得到:
../../lib/libopencv_videoio.so.3.1.0:引用av_frame_alloc' sin definir <br>../../lib/libopencv_videoio.so.3.1.0: referencia a av_frame_free'sin定义
collect2:错误:ld返回1退出状态
make [2]: * [bin/opencv_test_video]错误1
make [1]:*
[modules/video/CMakeFiles/opencv_test_video.dir/all]错误2

有人可以帮助我吗?

最佳答案

您可以引用这个对我有用的issue
我的问题通过设置-DWITH_V4AL=OFF-DWITH_LIBV4L=ON解决

07-27 13:37