mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-11-08 22:45:43 +00:00
84 lines
3.5 KiB
Diff
84 lines
3.5 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Nirbheek Chauhan <nirbheek@centricular.com>
|
|
Date: Wed, 21 Sep 2022 21:48:31 +0530
|
|
Subject: [PATCH] meson: Add a new option to control the source for orc
|
|
|
|
Previously we were unconditionally cloning the orc subproject because
|
|
we want the developer environment to use the latest orc. However, some
|
|
people want to use the system orc instead, or want to auto-detect
|
|
which to use, with the system orc getting preference. This requires
|
|
adding a new option to select that. See discussion at:
|
|
https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/2556
|
|
|
|
Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/1282
|
|
|
|
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3062>
|
|
---
|
|
meson.build | 22 +++++++++++++++++++++-
|
|
meson_options.txt | 1 +
|
|
subprojects/orc.wrap | 3 +++
|
|
3 files changed, 25 insertions(+), 1 deletion(-)
|
|
|
|
diff --git a/meson.build b/meson.build
|
|
index 03df4ab157df..5b714eb5ee8f 100644
|
|
--- a/meson.build
|
|
+++ b/meson.build
|
|
@@ -126,7 +126,19 @@ elif build_system == 'darwin'
|
|
subproject('macos-bison-binary')
|
|
endif
|
|
|
|
-orc_subproject = subproject('orc', required: get_option('orc'))
|
|
+orc_option = get_option('orc')
|
|
+# There is a check below to keep this in sync with subprojects/gst-plugins-base/meson.build
|
|
+orc_req = '>= 0.4.24'
|
|
+orc_source_option = get_option('orc-source')
|
|
+orc_subproject = disabler()
|
|
+if orc_option.allowed()
|
|
+ if orc_source_option == 'subproject'
|
|
+ orc_subproject = subproject('orc', required: orc_option)
|
|
+ else
|
|
+ dependency('orc-0.4', version: orc_req, required: orc_option,
|
|
+ allow_fallback: orc_source_option == 'auto')
|
|
+ endif
|
|
+endif
|
|
|
|
foreach custom_subproj: get_option('custom_subprojects').split(',')
|
|
if custom_subproj != ''
|
|
@@ -162,6 +174,14 @@ foreach sp : subprojects
|
|
subproj = subproject(project_name, required: is_required)
|
|
endif
|
|
|
|
+ if project_name == 'gst-plugins-base'
|
|
+ gst_base_orc_req = subproj.get_variable('orc_req', '')
|
|
+ if gst_base_orc_req != orc_req
|
|
+ error('orc_req is "@0@" but it should be "@1@" from subprojects/gst-plugins-base/meson.build'
|
|
+ .format(orc_req, gst_base_orc_req))
|
|
+ endif
|
|
+ endif
|
|
+
|
|
if subproj.found()
|
|
plugins = subproj.get_variable('plugins', [])
|
|
all_plugins += plugins
|
|
diff --git a/meson_options.txt b/meson_options.txt
|
|
index 7a43f3443098..a2d4203c22ef 100644
|
|
--- a/meson_options.txt
|
|
+++ b/meson_options.txt
|
|
@@ -33,6 +33,7 @@ option('gst-full-device-providers', type : 'string', value : '',
|
|
description : '''List of device providers to expose in gstreamer-full's ABI with the syntax plugin1:dp1;plugin2:dp1:dp2. By default '' will export all device provider of the enabled plugin.''')
|
|
option('gst-full-dynamic-types', type : 'string', value : '',
|
|
description : '''List of dynamic types to expose in gstreamer-full's ABI with the syntax plugin:dt1,dt2. By default '' will export all device provider of the enabled plugin.''')
|
|
+option('orc-source', type: 'combo', choices: ['system', 'subproject', 'auto'], value: 'subproject')
|
|
|
|
# License-related feature options
|
|
option('gpl', type: 'feature', value: 'disabled',
|
|
diff --git a/subprojects/orc.wrap b/subprojects/orc.wrap
|
|
index 690d8e368b38..a3b553a614fa 100644
|
|
--- a/subprojects/orc.wrap
|
|
+++ b/subprojects/orc.wrap
|
|
@@ -3,3 +3,6 @@ directory=orc
|
|
url=https://gitlab.freedesktop.org/gstreamer/orc.git
|
|
push-url=git@gitlab.freedesktop.org:gstreamer/orc.git
|
|
revision=887392103956a8733a750c4442e2664d5c26527d
|
|
+
|
|
+[provide]
|
|
+orc-0.4 = orc_dep
|