diff options
Diffstat (limited to 'recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0001-meson-fix-build-with-opencv-enabled-and-opencv4.-Fix.patch')
| -rw-r--r-- | recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0001-meson-fix-build-with-opencv-enabled-and-opencv4.-Fix.patch | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0001-meson-fix-build-with-opencv-enabled-and-opencv4.-Fix.patch b/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0001-meson-fix-build-with-opencv-enabled-and-opencv4.-Fix.patch new file mode 100644 index 000000000..874b8abc8 --- /dev/null +++ b/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0001-meson-fix-build-with-opencv-enabled-and-opencv4.-Fix.patch | |||
| @@ -0,0 +1,45 @@ | |||
| 1 | From f41f356aebee916910453031c06c111000f2f261 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Christoph Reiter <reiter.christoph@gmail.com> | ||
| 3 | Date: Sun, 5 May 2019 22:11:16 +0200 | ||
| 4 | Subject: [PATCH] meson: fix build with opencv=enabled and opencv4. Fixes #964 | ||
| 5 | |||
| 6 | Having the opencv feature enabled would lead to the opencv3 dependency | ||
| 7 | being required which failed with only opencv4 being available. | ||
| 8 | |||
| 9 | Instead don't require anything and error out at the end if the feature was enabled | ||
| 10 | but no dependency was found. | ||
| 11 | |||
| 12 | Upstream-Status: Backport [https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/commit/22c6a4085f8792d8af0cdabfe1664d55ca2dee11] | ||
| 13 | |||
| 14 | (cherry picked from commit 22c6a4085f8792d8af0cdabfe1664d55ca2dee11) | ||
| 15 | Signed-off-by: Andrey Zhizhikin <andrey.zhizhikin@leica-geosystems.com> | ||
| 16 | --- | ||
| 17 | gst-libs/gst/opencv/meson.build | 6 ++++-- | ||
| 18 | 1 file changed, 4 insertions(+), 2 deletions(-) | ||
| 19 | |||
| 20 | diff --git a/gst-libs/gst/opencv/meson.build b/gst-libs/gst/opencv/meson.build | ||
| 21 | index 3fd472fda..8dc2ad99b 100644 | ||
| 22 | --- a/gst-libs/gst/opencv/meson.build | ||
| 23 | +++ b/gst-libs/gst/opencv/meson.build | ||
| 24 | @@ -9,9 +9,9 @@ opencv_headers = [ | ||
| 25 | 'gstopencvvideofilter.h', | ||
| 26 | ] | ||
| 27 | |||
| 28 | -opencv_dep = dependency('opencv', version : '>= 3.0.0', required : get_option('opencv')) | ||
| 29 | +opencv_dep = dependency('opencv', version : '>= 3.0.0', required : false) | ||
| 30 | if not opencv_dep.found() | ||
| 31 | - opencv_dep = dependency('opencv4', version : '>= 4.0.0', required : get_option('opencv')) | ||
| 32 | + opencv_dep = dependency('opencv4', version : '>= 4.0.0', required : false) | ||
| 33 | endif | ||
| 34 | if opencv_dep.found() | ||
| 35 | gstopencv = library('gstopencv-' + api_version, | ||
| 36 | @@ -30,4 +30,6 @@ if opencv_dep.found() | ||
| 37 | dependencies : [gstvideo_dep, opencv_dep]) | ||
| 38 | |||
| 39 | install_headers(opencv_headers, subdir : 'gstreamer-1.0/gst/opencv') | ||
| 40 | +elif get_option('opencv').enabled() | ||
| 41 | + error('OpenCV support enabled but required dependencies were not found.') | ||
| 42 | endif | ||
| 43 | -- | ||
| 44 | 2.17.1 | ||
| 45 | |||
