I am trying to compile OpenCV with ffmpeg support on Centos7.
I installed ffmpeg from the EPEL repository, and installed `yum install ffmpeg ffmpeg-devel`.
When I tried to compiled using `cmake -G"Unix Makefiles" -DWITH_FFMPEG=1 .` I get the following output (I am only copying the video ouput section, please let me know if i should add more). > -- Video I/O:
-- DC1394 1.x: NO
-- DC1394 2.x: YES (ver 2.2.2)
-- FFMPEG: NO
-- avcodec: YES (ver 56.26.100)
-- avformat: YES (ver 56.25.101)
-- avutil: YES (ver 54.20.100)
-- swscale: YES (ver 3.1.101)
-- avresample: YES (ver 2.1.0)
-- GStreamer:
-- base: YES (ver 0.10.36)
-- video: YES (ver 0.10.36)
-- app: YES (ver 0.10.36)
-- riff: YES (ver 0.10.36)
-- pbutils: YES (ver 0.10.36)
This is confusing because it seems that cmake detects the libraries but not ffmpeg.
The other clue I got is that it seems that cmake fails a test it does at the beginning since it show:
>-- WARNING: Can't build ffmpeg test code
Looking a bit more I found that this test is done in `./cmake/OpenCVFindLibsVideo.cmake`, where it tries to compile the example `./cmake/checks/ffmpeg_test.cpp`. In my case I found that the variable `FFMPEG_LIBRARY_DIRS` is empty. I do not if this is useful but it is the only clue I found.
I am stuck at the moment and I will appreciate any suggestion.
↧