From d9ea46425ba886e479b658dc8e7f55cc175cfad7 Mon Sep 17 00:00:00 2001 From: Bernd Kuhls Date: Mon, 15 Aug 2016 17:03:39 +0200 Subject: [PATCH] package/ffmpeg: add optional support for opencv ffmpeg only needs the imgproc module of opencv: https://github.com/FFmpeg/FFmpeg/commit/15708f13477aaf2effdc0d7fc727507bc468335a Signed-off-by: Bernd Kuhls Signed-off-by: Thomas Petazzoni --- package/ffmpeg/ffmpeg.mk | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/package/ffmpeg/ffmpeg.mk b/package/ffmpeg/ffmpeg.mk index 91e7fa979a..1d041012e7 100644 --- a/package/ffmpeg/ffmpeg.mk +++ b/package/ffmpeg/ffmpeg.mk @@ -48,7 +48,6 @@ FFMPEG_CONF_OPTS = \ --disable-frei0r \ --disable-libopencore-amrnb \ --disable-libopencore-amrwb \ - --disable-libopencv \ --disable-libcdio \ --disable-libdc1394 \ --disable-libfaac \ @@ -249,6 +248,15 @@ else FFMPEG_CONF_OPTS += --disable-vdpau endif +# To avoid a circular dependency only use opencv if opencv itself does +# not depend on ffmpeg. +ifeq ($(BR2_PACKAGE_OPENCV_LIB_IMGPROC)x$(BR2_PACKAGE_OPENCV_WITH_FFMPEG),yx) +FFMPEG_CONF_OPTS += --enable-libopencv +FFMPEG_DEPENDENCIES += opencv +else +FFMPEG_CONF_OPTS += --disable-libopencv +endif + ifeq ($(BR2_PACKAGE_OPUS),y) FFMPEG_CONF_OPTS += --enable-libopus FFMPEG_DEPENDENCIES += opus -- 2.30.2