1 |
commit: 3961737db6b965b7ba0ca927c91c41f8f2becfe0 |
2 |
Author: Niklāvs Koļesņikovs <89q1r14hd <AT> relay <DOT> firefox <DOT> com> |
3 |
AuthorDate: Fri Dec 31 08:04:58 2021 +0000 |
4 |
Commit: Sam James <sam <AT> gentoo <DOT> org> |
5 |
CommitDate: Sat Jan 1 03:47:27 2022 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3961737d |
7 |
|
8 |
media-video/wireplumber: add patch that should fix remote clients |
9 |
|
10 |
Two Gentoo users have reported issues with getting networked protocols |
11 |
working. The patch added in this wireplumber-0.4.5-r3 revbump should |
12 |
fix their issues, as reported by one of them. |
13 |
|
14 |
Signed-off-by: Niklāvs Koļesņikovs <89q1r14hd <AT> relay.firefox.com> |
15 |
Signed-off-by: Sam James <sam <AT> gentoo.org> |
16 |
|
17 |
...-config-add-restricted-access-permissions.patch | 36 ++++++++ |
18 |
.../wireplumber/wireplumber-0.4.5-r3.ebuild | 102 +++++++++++++++++++++ |
19 |
2 files changed, 138 insertions(+) |
20 |
|
21 |
diff --git a/media-video/wireplumber/files/wireplumber-0.4.5-access-config-add-restricted-access-permissions.patch b/media-video/wireplumber/files/wireplumber-0.4.5-access-config-add-restricted-access-permissions.patch |
22 |
new file mode 100644 |
23 |
index 000000000000..213283131e0b |
24 |
--- /dev/null |
25 |
+++ b/media-video/wireplumber/files/wireplumber-0.4.5-access-config-add-restricted-access-permissions.patch |
26 |
@@ -0,0 +1,36 @@ |
27 |
+https://gitlab.freedesktop.org/pipewire/wireplumber/-/commit/703c35cfd44265e81595db29eed081c8785cda87 |
28 |
+ |
29 |
+From 703c35cfd44265e81595db29eed081c8785cda87 Mon Sep 17 00:00:00 2001 |
30 |
+From: Wim Taymans <wtaymans@××××××.com> |
31 |
+Date: Mon, 29 Nov 2021 09:25:18 +0100 |
32 |
+Subject: [PATCH] access-config: add restricted access permissions |
33 |
+ |
34 |
+When a pulse client connects with TCP, it is given the 'restricted' |
35 |
+access policy. Assign 'rx' permissions for those clients instead of |
36 |
+blocking forever. |
37 |
+ |
38 |
+See pipewire#1863 |
39 |
+--- |
40 |
+ src/config/main.lua.d/50-default-access-config.lua | 8 ++++++++ |
41 |
+ 1 file changed, 8 insertions(+) |
42 |
+ |
43 |
+diff --git a/src/config/main.lua.d/50-default-access-config.lua b/src/config/main.lua.d/50-default-access-config.lua |
44 |
+index 0282d4aa..6cf18bed 100644 |
45 |
+--- a/src/config/main.lua.d/50-default-access-config.lua |
46 |
++++ b/src/config/main.lua.d/50-default-access-config.lua |
47 |
+@@ -20,4 +20,12 @@ default_access.rules = { |
48 |
+ }, |
49 |
+ default_permissions = "rx", |
50 |
+ }, |
51 |
++ { |
52 |
++ matches = { |
53 |
++ { |
54 |
++ { "pipewire.access", "=", "restricted" }, |
55 |
++ }, |
56 |
++ }, |
57 |
++ default_permissions = "rx", |
58 |
++ }, |
59 |
+ } |
60 |
+-- |
61 |
+GitLab |
62 |
+ |
63 |
|
64 |
diff --git a/media-video/wireplumber/wireplumber-0.4.5-r3.ebuild b/media-video/wireplumber/wireplumber-0.4.5-r3.ebuild |
65 |
new file mode 100644 |
66 |
index 000000000000..599aed0c155c |
67 |
--- /dev/null |
68 |
+++ b/media-video/wireplumber/wireplumber-0.4.5-r3.ebuild |
69 |
@@ -0,0 +1,102 @@ |
70 |
+# Copyright 1999-2021 Gentoo Authors |
71 |
+# Distributed under the terms of the GNU General Public License v2 |
72 |
+ |
73 |
+EAPI=7 |
74 |
+ |
75 |
+LUA_COMPAT=( lua5-{3,4} ) |
76 |
+ |
77 |
+inherit lua-single meson systemd |
78 |
+ |
79 |
+if [[ ${PV} == 9999 ]]; then |
80 |
+ EGIT_REPO_URI="https://gitlab.freedesktop.org/pipewire/${PN}.git" |
81 |
+ EGIT_BRANCH="master" |
82 |
+ inherit git-r3 |
83 |
+else |
84 |
+ SRC_URI="https://gitlab.freedesktop.org/pipewire/${PN}/-/archive/${PV}/${P}.tar.gz" |
85 |
+ |
86 |
+ # One commit is in git, the rest are in a PR which should be merged soon |
87 |
+ # bug #817881 |
88 |
+ SRC_URI+=" https://dev.gentoo.org/~sam/distfiles/${CATEGORY}/${PN}/${PN}-0.4.5-endianness-fixes.patch.bz2" |
89 |
+ KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~riscv ~sparc ~x86" |
90 |
+fi |
91 |
+ |
92 |
+DESCRIPTION="Replacement for pipewire-media-session" |
93 |
+HOMEPAGE="https://gitlab.freedesktop.org/pipewire/wireplumber" |
94 |
+ |
95 |
+LICENSE="MIT" |
96 |
+SLOT="0/0.4" |
97 |
+IUSE="elogind systemd test" |
98 |
+ |
99 |
+REQUIRED_USE=" |
100 |
+ ${LUA_REQUIRED_USE} |
101 |
+ ?? ( elogind systemd ) |
102 |
+" |
103 |
+ |
104 |
+RESTRICT="!test? ( test )" |
105 |
+ |
106 |
+# introspection? ( dev-libs/gobject-introspection ) is valid but likely only used for doc building |
107 |
+BDEPEND=" |
108 |
+ dev-libs/glib |
109 |
+ dev-util/gdbus-codegen |
110 |
+ dev-util/glib-utils |
111 |
+" |
112 |
+ |
113 |
+DEPEND=" |
114 |
+ ${LUA_DEPS} |
115 |
+ >=dev-libs/glib-2.62 |
116 |
+ >=media-video/pipewire-0.3.42:= |
117 |
+ virtual/libc |
118 |
+ elogind? ( sys-auth/elogind ) |
119 |
+ systemd? ( sys-apps/systemd ) |
120 |
+" |
121 |
+ |
122 |
+# Any dev-lua/* deps get declared like this inside RDEPEND: |
123 |
+# $(lua_gen_cond_dep ' |
124 |
+# dev-lua/<NAME>[${LUA_USEDEP}] |
125 |
+# ') |
126 |
+RDEPEND="${DEPEND}" |
127 |
+ |
128 |
+DOCS=( {NEWS,README}.rst ) |
129 |
+ |
130 |
+PATCHES=( |
131 |
+ "${FILESDIR}"/${P}-m-reserve-device-replace-the-hash-table-key-on-new-i.patch |
132 |
+ "${FILESDIR}"/${P}-policy-node-wait-for-nodes-when-we-become-unlinked.patch |
133 |
+ "${FILESDIR}"/${P}-lib-don-t-read-hidden-files-from-the-config-director.patch |
134 |
+ "${FILESDIR}"/${P}-alsa-handle-the-release-requested-signal.patch |
135 |
+ "${FILESDIR}"/${P}-access-config-add-restricted-access-permissions.patch |
136 |
+ "${WORKDIR}"/${P}-endianness-fixes.patch |
137 |
+) |
138 |
+ |
139 |
+src_configure() { |
140 |
+ local emesonargs=( |
141 |
+ -Dintrospection=disabled # Only used for Sphinx doc generation |
142 |
+ -Dsystem-lua=true # We always unbundle everything we can |
143 |
+ -Dsystem-lua-version=$(ver_cut 1-2 $(lua_get_version)) |
144 |
+ $(meson_feature elogind) |
145 |
+ $(meson_feature systemd) |
146 |
+ -Dsystemd-system-service=false # Matches upstream |
147 |
+ $(meson_use systemd systemd-user-service) |
148 |
+ -Dsystemd-system-unit-dir=$(systemd_get_systemunitdir) |
149 |
+ -Dsystemd-user-unit-dir=$(systemd_get_userunitdir) |
150 |
+ $(meson_use test tests) |
151 |
+ ) |
152 |
+ |
153 |
+ meson_src_configure |
154 |
+} |
155 |
+ |
156 |
+pkg_postinst() { |
157 |
+ if systemd_is_booted ; then |
158 |
+ ewarn "pipewire-media-session.service is no longer installed. You must switch" |
159 |
+ ewarn "to wireplumber.service user unit before your next logout/reboot:" |
160 |
+ ewarn "systemctl --user disable pipewire-media-session.service" |
161 |
+ ewarn "systemctl --user --force enable wireplumber.service" |
162 |
+ else |
163 |
+ ewarn "Switch to WirePlumber will happen the next time gentoo-pipewire-launcher" |
164 |
+ ewarn "is started (a replacement for directly calling pipewire binary)." |
165 |
+ ewarn |
166 |
+ ewarn "Please ensure that ${EROOT}/etc/pipewire/pipewire.conf either does not exist" |
167 |
+ ewarn "or, if it does exist, that any reference to" |
168 |
+ ewarn "${EROOT}/usr/bin/pipewire-media-session is commented out (begins with a #)." |
169 |
+ fi |
170 |
+ ewarn |
171 |
+} |