summaryrefslogtreecommitdiff
path: root/media-video/wireplumber
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2022-01-16 20:27:28 +0000
committerV3n3RiX <venerix@koprulu.sector>2022-01-16 20:27:28 +0000
commit2fd57282f0262ca084e05b0f2c63fbada395d02b (patch)
tree4e0f23cea9ce9fd972e70ebc5214bf36fed465cc /media-video/wireplumber
parentc3bc61051d7f12b4c682efa7a5460bbc8815649e (diff)
gentoo resync : 16.01.2021
Diffstat (limited to 'media-video/wireplumber')
-rw-r--r--media-video/wireplumber/Manifest10
-rw-r--r--media-video/wireplumber/files/wireplumber-0.4.6-endianness-fixes.patch229
-rw-r--r--media-video/wireplumber/files/wireplumber-0.4.6-policy-node-find-best-linkable-if-default-one-cannot.patch48
-rw-r--r--media-video/wireplumber/files/wireplumber-0.4.6-policy-node-fix-typo-when-finding-best-target.patch27
-rw-r--r--media-video/wireplumber/files/wireplumber-0.4.6-policy-node-schedule-a-rescan-without-timeout-if-def.patch50
-rw-r--r--media-video/wireplumber/files/wireplumber-0.4.6-spa-pod-fix-different-architecture-errors-for-boolea.patch40
-rw-r--r--media-video/wireplumber/files/wireplumber-0.4.7-default-nodes-handle-nodes-without-Routes.patch51
-rw-r--r--media-video/wireplumber/wireplumber-0.4.6-r1.ebuild97
-rw-r--r--media-video/wireplumber/wireplumber-0.4.7-r1.ebuild (renamed from media-video/wireplumber/wireplumber-0.4.6.ebuild)2
9 files changed, 322 insertions, 232 deletions
diff --git a/media-video/wireplumber/Manifest b/media-video/wireplumber/Manifest
index 63e02876421a..266439408229 100644
--- a/media-video/wireplumber/Manifest
+++ b/media-video/wireplumber/Manifest
@@ -4,12 +4,18 @@ AUX wireplumber-0.4.5-default-routes.lua-reevaluate-current-profile-only-f.patch
AUX wireplumber-0.4.5-lib-don-t-read-hidden-files-from-the-config-director.patch 742 BLAKE2B 480dfc48954a13323bc171e3b4672cedad27fdde05d8f28e263eddffd80c51ecdaa5046c30f57cd1a28a08270e59a38a3202fe496e4af84494d3b52614858880 SHA512 5400a2d4d1e61abe8d6c22c6540a83fafb25b6f4555156b66de9ad8350ce176faed00099c7a40b5286c82644ee09b5890da2521078f91e51d5a66fce7ed82a2a
AUX wireplumber-0.4.5-m-reserve-device-replace-the-hash-table-key-on-new-i.patch 1672 BLAKE2B a5d8911754670c9303e35d15df45ecdd5bb4b2d837dea2000ff5e102bfb789ea678ace39356579f0fc86273ec58a7c5cc6eea701c3b7a274d742cddfaa3575d3 SHA512 8605622ed43fef37e1ca49edaae4812618e5ad83904b682b2b903e9de92060fd9b4a0a025d5716cd16339b94ae67b1ee9622949fae73153df0bbc5b9b3c2ebd9
AUX wireplumber-0.4.5-policy-node-wait-for-nodes-when-we-become-unlinked.patch 1203 BLAKE2B 12e07a42d99187cba61d5428c235aba9207bd708e9346d53618b92c0ed06893e6295dbb49b9529e198f53c7ce4b573b897c349de8bb688273656de237ab3bca1 SHA512 4a5bb0a79c507945652a5600304fae1c9bf6fe028053a890c1633be2c82491ada487c9943ac29c6ed26f9e86a5d7f76140ec78bbaa394e41e1f082d50a7b56ef
-AUX wireplumber-0.4.6-endianness-fixes.patch 8766 BLAKE2B b66d2176c88e1df5a3c9ecd78bff307bf97633c02e2a905fd70bf6d3a08d6cbaa935d769d763e76a95bf94240ff764a349758b9115d08aba6fb772388692a989 SHA512 ec75f535af1933f0432c87a3370156ffddc1acd7b2def92b7e4ff92a86d7d2758596acee9eed067cfb5fa4b465845ae93bad0db23414f06ce32ccad2ec0831fd
+AUX wireplumber-0.4.6-policy-node-find-best-linkable-if-default-one-cannot.patch 1612 BLAKE2B a207499560853e4c5c98e721a4e56abf4b6784b1d21eafc1c2c9021c6e103c4a111d8cc98b4699a50c412a9f5cdc5103df0ae7502c640dde75a31f08d01cf509 SHA512 43e4554a666c4c3af904707bb05f8d2449d73c70b98aa3da874429d7264fa33dcc3e666cd2beb596f95f88a03f15f901aa31b45bd4f49cc6759b15dd07c4a067
+AUX wireplumber-0.4.6-policy-node-fix-typo-when-finding-best-target.patch 810 BLAKE2B 2a93b30ad454ec57c12d658b9ad5341df1d7f9ffafb8b31b81d9beb803587ec604f5664c2d4414fba8f9f84e11a9d0d107de4be76498a0070e8b9da808594c1f SHA512 123b344aac418132de49a46928e2ecb242124a6a3e2df787050cd2d9f6d5a9dda72583445daaf39d0a35d1519a95e3cb33175b517333432849ed95141db3ab6b
+AUX wireplumber-0.4.6-policy-node-schedule-a-rescan-without-timeout-if-def.patch 1743 BLAKE2B 60955b67413f59ad7d9bbf962d9d226458416f39a45200f75602913a5d59038ad2bd65f12af461261b7ad76efffab9e9ebb11279e9a7a5a5b3e1360369ee1f84 SHA512 0916b4b7851b9303ef404c4026f39bb15a4f8cf433da5c96f32d510f8654997ba5e3f8b6b3891f7eab5ac5722096eed6fbbe2998cd2f9e72ae090efefb064420
+AUX wireplumber-0.4.6-spa-pod-fix-different-architecture-errors-for-boolea.patch 1253 BLAKE2B 933f5d49c34a4fd024b866c839b429ab6c0a0f13ac6864d03f91a05a87a8b724fca9faa8302ae6a3852738bdee8f2c5e4dff364b46dcbe3377939f0b3856f93a SHA512 e568ec08b9948a774fcc48024476582bc3b93d4db467ce1d4797c7e4e04b91c863c57aae1faa17686e8f07e780f8b25dceb40695033a181814452c895dba75d3
+AUX wireplumber-0.4.7-default-nodes-handle-nodes-without-Routes.patch 1837 BLAKE2B 7a621e0903283c9856c02844763d7091930ef122e3bee0577a556390cf7a0051d3cf26ca2af92b07ed055d4e9c925129a43e0cbf4830c0e4a8f9a06a8b36fe56 SHA512 6b3b3304a30f6b5c8f4fc2e2249596bc1f283b76962b529cdd16e534ada2e0e04f4620dedf85a9c974fab199878badc7d79e37b046f8381096d1a0957ead7a11
DIST wireplumber-0.4.5-endianness-fixes.patch.bz2 2341 BLAKE2B 225b164a4624128b50fe8691e3577de9aea35e85ed0527c605a617227d96ad49646b658da120d118ab45fd1ed82ed188ad1073b0a8954632ec6501535d533009 SHA512 d5b64612aad6d462ffbc78a24cf50ebde83b29e183a6d169976f5d8fdb0ec3c72984135ee75d52f7d7e8261716482ca277c49cf5824028bfaf33e596857de97f
DIST wireplumber-0.4.5.tar.gz 345035 BLAKE2B 177984901790228d8ddeb8ee2a548eb53db07c8077734590c3f964df36cfa47a4099e049ae9a19a136f4147c75b7122359a73b8387a641768f71484b9c4ab119 SHA512 b0d5962e7a83709cc3115fbf0a04b63660085aeea2ebda6d78d692065ccb193cea8b44bb506fa440cf0b88bfae71a4f69a192cd6cba885ebf3c9270bea50c67a
DIST wireplumber-0.4.6.tar.gz 357392 BLAKE2B 03942930b1eafb37071c0f38071567fb6117a9a64b91f064982eafa34a8662e1cba26b634db9c74a4e0bd0a8765d9b827ab2afd5e364c6377fa7ecbc7e32c5d1 SHA512 4b4b9aff6e0e6d7c567e20e4df533cfd16287f2e7498ae8533a9a4251066e6d0a9cd99e3da48f525bb2010053f7c9918fe09a5ade39c8830ec08c24292527684
+DIST wireplumber-0.4.7.tar.gz 358718 BLAKE2B a7e708ccfb9e95b3f3e2ddc5dfc1dc437ac8a2831a7cdaf03f33af65fcce8fc27dd91b2a6f346e60f68873724c2d165616005b485189604863213b5d5565f894 SHA512 8b472e1b3c7a29045326b30989d24224e510f93021c1b5b6aee59859daf594e91a738b8ad9d46d24736b7de29624d9faff40e1061bd3eddc559c95e325bfbf19
EBUILD wireplumber-0.4.5-r2.ebuild 3056 BLAKE2B 2485dea8d7a93b14231de12023ed023483abe1135a9dfed26779d4e4b14b514c01d0aa8fed279156be9165c60a5907ce01bc621a4f188e572246cba96d1c3a5b SHA512 a10e4d07bf89f035d4b81d6f1162d5dc584a4981dbb106451f6c7d45fbe8b1f71311cbafc2cdaea2d953ede18bb1f7743911ad06d99dd5a1a3b8d5577c027817
EBUILD wireplumber-0.4.5-r4.ebuild 3271 BLAKE2B f69305218c798f6f34aa3e3716d8abfe2f32795286d46aa5412bad3d5d1fc717bbb92249e1c2ae3449a5f93e50b0d0ef942f02835140ca764c768ecfbf16435e SHA512 8f00d21c53f7911bf325133c4aedcc2b215630e2e7736e4f8f06557becd2d394f8006cc83fd4d0f2e26a3c40dd0b372e94520119e9a59902c46940ec574fef7f
-EBUILD wireplumber-0.4.6.ebuild 2619 BLAKE2B 1fb3e7a073e1e043c1eed9785a385e72fd6df3f10b2225e8c123ec930d8a6f2da8ac96424cc9147a4215ff05861a142c0744d173b1a87a72c17ed78ce2bd8436 SHA512 99b07db549ff61cb44cdd937cdfb637aeec49ed902e3f7e595e605b841490a85881513c0c618e45b4026c2362137c510ec9a6deb5ca935cf42d5d0ca8faff9f0
+EBUILD wireplumber-0.4.6-r1.ebuild 2885 BLAKE2B 9c1d9494281187560add126aef3642133220f7032118863e9ff3e7eec1e9f5e665907960accc089ba325040a3390147887a95532d6c04a59afa01f4c325cc2d7 SHA512 119aec5c069a3766725829e3db98340e281982d13502ba7759d9a4be345074d2b889ef0e3f14112c68368eb2e4154cff54536288914391cc7c994c81e0192c96
+EBUILD wireplumber-0.4.7-r1.ebuild 2644 BLAKE2B 68ddc0730654f5f112d388aca3ee40d5770b5e3c55944c09a5a3a3503e15b752fc0e05856e72a683718106ab83932240fbb59235af860981cbf78058bd86fade SHA512 8e8bcda79de1d7ca4b044049ac2cbb6e5b596f6f8a351b8f67d4dc237252e6ca31f894c069966213c1c85ec85a76643a5a8da268768e69faa696c6b4cd6cf45c
EBUILD wireplumber-9999.ebuild 2563 BLAKE2B cb53fa8c1fe7b0dadd01ae5b703b10d1b3202104039bff37a06e22777e822fe3178a89f42a3172acccb575c0c9dda14c420095587b66ee2baa530a41fe2a5235 SHA512 6558a682dfff705adf1aa10c2e3e2b6cc2efed6330b0b57a9744e6e620bd264f4c1cf236770f1178f668a7931c5fa710b51cb195a5b6911200ae8fb404fa5a05
MISC metadata.xml 673 BLAKE2B 71a411815b61a970653e39cf33ef56e04268805b98d5d5fbc405f4739b71adee9137e0198bf4ebaad208b4e878ab3087766ee223e1e18aaff90fac14d2c5dc23 SHA512 ba6121c54e9f6208b0b5c471790b005c51105d479a0dd2464563b7320530b3d8c176ff38bdb6c760d3f31a18fb993647244d944a222991110f14508ce63c4a96
diff --git a/media-video/wireplumber/files/wireplumber-0.4.6-endianness-fixes.patch b/media-video/wireplumber/files/wireplumber-0.4.6-endianness-fixes.patch
deleted file mode 100644
index 9b8bba93a8ab..000000000000
--- a/media-video/wireplumber/files/wireplumber-0.4.6-endianness-fixes.patch
+++ /dev/null
@@ -1,229 +0,0 @@
-Bunch of patches from https://gitlab.freedesktop.org/pipewire/wireplumber/-/issues/49
-Requires pipewire 0.3.42 for 03f0a7c9bac3e61126fc852e543b8ea254471eb7.
-
---- a/tests/wp/spa-pod.c
-+++ b/tests/wp/spa-pod.c
-@@ -6,6 +6,8 @@
- * SPDX-License-Identifier: MIT
- */
-
-+#include <stdbool.h>
-+
- #include <wp/wp.h>
-
- static void
-@@ -428,12 +430,12 @@ test_spa_pod_object (void)
- wp_spa_type_name (wp_spa_pod_get_spa_type (pod)));
-
- const char *id_name;
-- gboolean mute = TRUE;
-+ bool mute = true;
- float vol = 0.0;
- gint32 frequency;
- const char *device;
- gint64 device_fd;
-- gboolean custom = FALSE;
-+ bool custom = false;
- g_assert_true (wp_spa_pod_get_object (pod,
- &id_name,
- "mute", "b", &mute,
-@@ -475,12 +477,12 @@ test_spa_pod_object (void)
- wp_spa_type_name (wp_spa_pod_get_spa_type (pod)));
-
- const char *id_name;
-- gboolean mute = TRUE;
-+ bool mute = true;
- float vol = 0.0;
- gint32 frequency;
- const char *device;
- gint64 device_fd;
-- gboolean custom = FALSE;
-+ bool custom = false;
- g_autoptr (WpSpaPodParser) p = wp_spa_pod_parser_new_object (pod, &id_name);
- g_assert_nonnull (pod);
- g_assert_true (wp_spa_pod_parser_get (p, "mute", "b", &mute, NULL));
-@@ -603,7 +605,7 @@ test_spa_pod_struct (void)
- g_assert_true (wp_spa_pod_parser_get (p, "P", &value_object, NULL));
- g_assert_nonnull (value_object);
- const char *id_name;
-- gboolean mute = TRUE;
-+ bool mute = true;
-
- g_assert_true (wp_spa_pod_get_object (value_object,
- &id_name,
---- a/tests/wp/endpoint.c
-+++ b/tests/wp/endpoint.c
-@@ -499,7 +499,7 @@ test_endpoint_with_props (TestEndpointFixture *fixture, gconstpointer data)
- g_auto (GValue) item = G_VALUE_INIT;
- g_autoptr (WpSpaPod) pod = NULL;
- gfloat float_value = 0.0f;
-- gboolean boolean_value = TRUE;
-+ bool boolean_value = true;
-
- iterator = wp_pipewire_object_enum_params_sync (
- WP_PIPEWIRE_OBJECT (fixture->proxy_endpoint), "Props", NULL);
-@@ -513,7 +513,7 @@ test_endpoint_with_props (TestEndpointFixture *fixture, gconstpointer data)
- "mute", "b", &boolean_value,
- NULL));
- g_assert_cmpfloat_with_epsilon (float_value, 1.0f, 0.001);
-- g_assert_cmpint (boolean_value, ==, FALSE);
-+ g_assert_cmpint (boolean_value, ==, false);
- }
-
- /* setup change signals */
-@@ -541,7 +541,7 @@ test_endpoint_with_props (TestEndpointFixture *fixture, gconstpointer data)
- g_auto (GValue) item = G_VALUE_INIT;
- g_autoptr (WpSpaPod) pod = NULL;
- gfloat float_value = 0.0f;
-- gboolean boolean_value = TRUE;
-+ bool boolean_value = true;
-
- iterator = wp_pipewire_object_enum_params_sync (
- WP_PIPEWIRE_OBJECT (fixture->proxy_endpoint), "Props", NULL);
-@@ -556,14 +556,14 @@ test_endpoint_with_props (TestEndpointFixture *fixture, gconstpointer data)
- "mute", "b", &boolean_value,
- NULL));
- g_assert_cmpfloat_with_epsilon (float_value, 0.7f, 0.001);
-- g_assert_cmpint (boolean_value, ==, FALSE);
-+ g_assert_cmpint (boolean_value, ==, false);
- }
- {
- g_autoptr (WpIterator) iterator = NULL;
- g_auto (GValue) item = G_VALUE_INIT;
- g_autoptr (WpSpaPod) pod = NULL;
- gfloat float_value = 0.0f;
-- gboolean boolean_value = TRUE;
-+ bool boolean_value = true;
-
- iterator = wp_pipewire_object_enum_params_sync (
- WP_PIPEWIRE_OBJECT (fixture->impl_endpoint), "Props", NULL);
-@@ -577,14 +577,14 @@ test_endpoint_with_props (TestEndpointFixture *fixture, gconstpointer data)
- "mute", "b", &boolean_value,
- NULL));
- g_assert_cmpfloat_with_epsilon (float_value, 0.7f, 0.001);
-- g_assert_cmpint (boolean_value, ==, FALSE);
-+ g_assert_cmpint (boolean_value, ==, false);
- }
- {
- g_autoptr (WpIterator) iterator = NULL;
- g_auto (GValue) item = G_VALUE_INIT;
- g_autoptr (WpSpaPod) pod = NULL;
- gfloat float_value = 0.0f;
-- gboolean boolean_value = TRUE;
-+ bool boolean_value = true;
-
- iterator = wp_pipewire_object_enum_params_sync (
- WP_PIPEWIRE_OBJECT (endpoint->node), "Props", NULL);
-@@ -598,7 +598,7 @@ test_endpoint_with_props (TestEndpointFixture *fixture, gconstpointer data)
- "mute", "b", &boolean_value,
- NULL));
- g_assert_cmpfloat_with_epsilon (float_value, 0.7f, 0.001);
-- g_assert_cmpint (boolean_value, ==, FALSE);
-+ g_assert_cmpint (boolean_value, ==, false);
- }
-
- /* change control on the impl */
-@@ -618,7 +618,7 @@ test_endpoint_with_props (TestEndpointFixture *fixture, gconstpointer data)
- g_auto (GValue) item = G_VALUE_INIT;
- g_autoptr (WpSpaPod) pod = NULL;
- gfloat float_value = 0.0f;
-- gboolean boolean_value = TRUE;
-+ bool boolean_value = true;
-
- iterator = wp_pipewire_object_enum_params_sync (
- WP_PIPEWIRE_OBJECT (fixture->proxy_endpoint), "Props", NULL);
-@@ -633,14 +633,14 @@ test_endpoint_with_props (TestEndpointFixture *fixture, gconstpointer data)
- "mute", "b", &boolean_value,
- NULL));
- g_assert_cmpfloat_with_epsilon (float_value, 0.7f, 0.001);
-- g_assert_cmpint (boolean_value, ==, TRUE);
-+ g_assert_cmpint (boolean_value, ==, true);
- }
- {
- g_autoptr (WpIterator) iterator = NULL;
- g_auto (GValue) item = G_VALUE_INIT;
- g_autoptr (WpSpaPod) pod = NULL;
- gfloat float_value = 0.0f;
-- gboolean boolean_value = TRUE;
-+ bool boolean_value = true;
-
- iterator = wp_pipewire_object_enum_params_sync (
- WP_PIPEWIRE_OBJECT (fixture->impl_endpoint), "Props", NULL);
-@@ -654,14 +654,14 @@ test_endpoint_with_props (TestEndpointFixture *fixture, gconstpointer data)
- "mute", "b", &boolean_value,
- NULL));
- g_assert_cmpfloat_with_epsilon (float_value, 0.7f, 0.001);
-- g_assert_cmpint (boolean_value, ==, TRUE);
-+ g_assert_cmpint (boolean_value, ==, true);
- }
- {
- g_autoptr (WpIterator) iterator = NULL;
- g_auto (GValue) item = G_VALUE_INIT;
- g_autoptr (WpSpaPod) pod = NULL;
- gfloat float_value = 0.0f;
-- gboolean boolean_value = TRUE;
-+ bool boolean_value = true;
-
- iterator = wp_pipewire_object_enum_params_sync (
- WP_PIPEWIRE_OBJECT (endpoint->node), "Props", NULL);
-@@ -675,7 +675,7 @@ test_endpoint_with_props (TestEndpointFixture *fixture, gconstpointer data)
- "mute", "b", &boolean_value,
- NULL));
- g_assert_cmpfloat_with_epsilon (float_value, 0.7f, 0.001);
-- g_assert_cmpint (boolean_value, ==, TRUE);
-+ g_assert_cmpint (boolean_value, ==, true);
- }
-
- /* change control on the node */
-@@ -695,7 +695,7 @@ test_endpoint_with_props (TestEndpointFixture *fixture, gconstpointer data)
- g_auto (GValue) item = G_VALUE_INIT;
- g_autoptr (WpSpaPod) pod = NULL;
- gfloat float_value = 0.0f;
-- gboolean boolean_value = TRUE;
-+ bool boolean_value = true;
-
- iterator = wp_pipewire_object_enum_params_sync (
- WP_PIPEWIRE_OBJECT (fixture->proxy_endpoint), "Props", NULL);
-@@ -709,14 +709,14 @@ test_endpoint_with_props (TestEndpointFixture *fixture, gconstpointer data)
- "mute", "b", &boolean_value,
- NULL));
- g_assert_cmpfloat_with_epsilon (float_value, 0.2f, 0.001);
-- g_assert_cmpint (boolean_value, ==, TRUE);
-+ g_assert_cmpint (boolean_value, ==, true);
- }
- {
- g_autoptr (WpIterator) iterator = NULL;
- g_auto (GValue) item = G_VALUE_INIT;
- g_autoptr (WpSpaPod) pod = NULL;
- gfloat float_value = 0.0f;
-- gboolean boolean_value = TRUE;
-+ bool boolean_value = true;
-
- iterator = wp_pipewire_object_enum_params_sync (
- WP_PIPEWIRE_OBJECT (fixture->impl_endpoint), "Props", NULL);
-@@ -730,14 +730,14 @@ test_endpoint_with_props (TestEndpointFixture *fixture, gconstpointer data)
- "mute", "b", &boolean_value,
- NULL));
- g_assert_cmpfloat_with_epsilon (float_value, 0.2f, 0.001);
-- g_assert_cmpint (boolean_value, ==, TRUE);
-+ g_assert_cmpint (boolean_value, ==, true);
- }
- {
- g_autoptr (WpIterator) iterator = NULL;
- g_auto (GValue) item = G_VALUE_INIT;
- g_autoptr (WpSpaPod) pod = NULL;
- gfloat float_value = 0.0f;
-- gboolean boolean_value = TRUE;
-+ bool boolean_value = true;
-
- iterator = wp_pipewire_object_enum_params_sync (
- WP_PIPEWIRE_OBJECT (endpoint->node), "Props", NULL);
-@@ -751,7 +751,7 @@ test_endpoint_with_props (TestEndpointFixture *fixture, gconstpointer data)
- "mute", "b", &boolean_value,
- NULL));
- g_assert_cmpfloat_with_epsilon (float_value, 0.2f, 0.001);
-- g_assert_cmpint (boolean_value, ==, TRUE);
-+ g_assert_cmpint (boolean_value, ==, true);
- }
-
- /* destroy impl endpoint */
diff --git a/media-video/wireplumber/files/wireplumber-0.4.6-policy-node-find-best-linkable-if-default-one-cannot.patch b/media-video/wireplumber/files/wireplumber-0.4.6-policy-node-find-best-linkable-if-default-one-cannot.patch
new file mode 100644
index 000000000000..0cedea4ac6be
--- /dev/null
+++ b/media-video/wireplumber/files/wireplumber-0.4.6-policy-node-find-best-linkable-if-default-one-cannot.patch
@@ -0,0 +1,48 @@
+https://gitlab.freedesktop.org/pipewire/wireplumber/-/commit/bee9827ae376b75feceea926b0afc727fecca51b
+
+From bee9827ae376b75feceea926b0afc727fecca51b Mon Sep 17 00:00:00 2001
+From: Julian Bouzas <julian.bouzas@collabora.com>
+Date: Fri, 7 Jan 2022 15:35:10 -0500
+Subject: [PATCH] policy-node: find best linkable if default one cannot be
+ linked
+
+Fixes issue with echo cancellation pipewire module.
+---
+ src/scripts/policy-node.lua | 19 ++++++++++++++-----
+ 1 file changed, 14 insertions(+), 5 deletions(-)
+
+diff --git a/src/scripts/policy-node.lua b/src/scripts/policy-node.lua
+index c273c1fe..9df50072 100644
+--- a/src/scripts/policy-node.lua
++++ b/src/scripts/policy-node.lua
+@@ -477,13 +477,22 @@ function findBestLinkable (si)
+ end
+
+ function findUndefinedTarget (si)
+- -- Find the default linkable if the default nodes module is loaded, otherwise
+- -- just find the best linkable based on priority and routes
+- if default_nodes ~= nil then
+- return findDefaultlinkable (si)
+- else
++ -- Just find the best linkable if default nodes module is not loaded
++ if default_nodes == nil then
+ return findBestLinkable (si)
+ end
++
++ -- Otherwise find the default linkable. If the default linkabke cannot link,
++ -- we find the best one instead. We return nil if default does not exist.
++ local si_target, can_passthrough = findDefaultlinkable (si)
++ if si_target then
++ if canLink (si.properties, si_target) then
++ return si_target, can_passthrough
++ else
++ return findBestLinkable (si)
++ end
++ end
++ return nil, nil
+ end
+
+ function lookupLink (si_id, si_target_id)
+--
+GitLab
+
diff --git a/media-video/wireplumber/files/wireplumber-0.4.6-policy-node-fix-typo-when-finding-best-target.patch b/media-video/wireplumber/files/wireplumber-0.4.6-policy-node-fix-typo-when-finding-best-target.patch
new file mode 100644
index 000000000000..f18920c475a8
--- /dev/null
+++ b/media-video/wireplumber/files/wireplumber-0.4.6-policy-node-fix-typo-when-finding-best-target.patch
@@ -0,0 +1,27 @@
+https://gitlab.freedesktop.org/pipewire/wireplumber/-/commit/23fc4d21a9cfad492f8d3a367e438115197dff4a
+
+From 23fc4d21a9cfad492f8d3a367e438115197dff4a Mon Sep 17 00:00:00 2001
+From: Julian Bouzas <julian.bouzas@collabora.com>
+Date: Fri, 7 Jan 2022 10:12:04 -0500
+Subject: [PATCH] policy-node: fix typo when finding best target
+
+---
+ src/scripts/policy-node.lua | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/scripts/policy-node.lua b/src/scripts/policy-node.lua
+index 0d716c1c..8ca5a695 100644
+--- a/src/scripts/policy-node.lua
++++ b/src/scripts/policy-node.lua
+@@ -482,7 +482,7 @@ function findUndefinedTarget (si)
+ if default_nodes ~= nil then
+ return findDefaultlinkable (si)
+ else
+- return findBestlinkable (si)
++ return findBestLinkable (si)
+ end
+ end
+
+--
+GitLab
+
diff --git a/media-video/wireplumber/files/wireplumber-0.4.6-policy-node-schedule-a-rescan-without-timeout-if-def.patch b/media-video/wireplumber/files/wireplumber-0.4.6-policy-node-schedule-a-rescan-without-timeout-if-def.patch
new file mode 100644
index 000000000000..28b5a5ea22a4
--- /dev/null
+++ b/media-video/wireplumber/files/wireplumber-0.4.6-policy-node-schedule-a-rescan-without-timeout-if-def.patch
@@ -0,0 +1,50 @@
+https://gitlab.freedesktop.org/pipewire/wireplumber/-/commit/afe71d7e48c28b0ae5cbd9327433e3c55c103fcb
+
+From afe71d7e48c28b0ae5cbd9327433e3c55c103fcb Mon Sep 17 00:00:00 2001
+From: Julian Bouzas <julian.bouzas@collabora.com>
+Date: Thu, 6 Jan 2022 10:53:38 -0500
+Subject: [PATCH] policy-node: schedule a rescan without timeout if defined
+ target is not found
+
+Fixes #146
+---
+ src/scripts/policy-node.lua | 17 ++++-------------
+ 1 file changed, 4 insertions(+), 13 deletions(-)
+
+diff --git a/src/scripts/policy-node.lua b/src/scripts/policy-node.lua
+index 8ca5a695..c273c1fe 100644
+--- a/src/scripts/policy-node.lua
++++ b/src/scripts/policy-node.lua
+@@ -552,25 +552,16 @@ function handleLinkable (si)
+ si_target = nil
+ end
+
+- -- wait up to 2 seconds for the requested target to become available
+- -- this is because the client may have already "seen" a target that we haven't
+- -- yet prepared, which leads to a race condition
++ -- if the client has seen a target that we haven't yet prepared, schedule
++ -- a rescan one more time and hope for the best
+ local si_id = si.id
+ if si_props["node.target"] and si_props["node.target"] ~= "-1"
+ and not si_target
+ and not si_flags[si_id].was_handled
+ and not si_flags[si_id].done_waiting then
+- if not si_flags[si_id].timeout_source then
+- si_flags[si_id].timeout_source = Core.timeout_add(2000, function()
+- if si_flags[si_id] then
+- si_flags[si_id].done_waiting = true
+- si_flags[si_id].timeout_source = nil
+- scheduleRescan()
+- end
+- return false
+- end)
+- end
+ Log.info (si, "... waiting for target")
++ si_flags[si_id].done_waiting = true
++ scheduleRescan()
+ return
+ end
+
+--
+GitLab
+
diff --git a/media-video/wireplumber/files/wireplumber-0.4.6-spa-pod-fix-different-architecture-errors-for-boolea.patch b/media-video/wireplumber/files/wireplumber-0.4.6-spa-pod-fix-different-architecture-errors-for-boolea.patch
new file mode 100644
index 000000000000..b11a2f6f70f6
--- /dev/null
+++ b/media-video/wireplumber/files/wireplumber-0.4.6-spa-pod-fix-different-architecture-errors-for-boolea.patch
@@ -0,0 +1,40 @@
+https://gitlab.freedesktop.org/julian/wireplumber/-/commit/5afd176698aee835c8812eb7944ba12da53ffeab
+
+From 5afd176698aee835c8812eb7944ba12da53ffeab Mon Sep 17 00:00:00 2001
+From: Julian Bouzas <julian.bouzas@collabora.com>
+Date: Mon, 13 Dec 2021 12:01:52 -0500
+Subject: [PATCH] spa-pod: fix different architecture errors for boolean values
+
+---
+ lib/wp/spa-pod.c | 8 ++++++++
+ 1 file changed, 8 insertions(+)
+
+diff --git a/lib/wp/spa-pod.c b/lib/wp/spa-pod.c
+index c1c22572..bd7b8876 100644
+--- a/lib/wp/spa-pod.c
++++ b/lib/wp/spa-pod.c
+@@ -2332,6 +2332,10 @@ wp_spa_pod_builder_add_valist (WpSpaPodBuilder *self, va_list args)
+ }
+ break;
+ }
++ case 'b':
++ spa_pod_builder_bool(&self->builder,
++ va_arg(args, gboolean) ? true : false);
++ break;
+ default:
+ SPA_POD_BUILDER_COLLECT(&self->builder, *format, args);
+ break;
+@@ -2778,6 +2782,10 @@ wp_spa_pod_parser_get_valist (WpSpaPodParser *self, va_list args)
+ }
+ break;
+ }
++ case 'b':
++ *va_arg(args, gboolean*) =
++ SPA_POD_VALUE(struct spa_pod_bool, pod) ? TRUE : FALSE;
++ break;
+ default:
+ SPA_POD_PARSER_COLLECT (pod, *format, args);
+ break;
+--
+GitLab
+
diff --git a/media-video/wireplumber/files/wireplumber-0.4.7-default-nodes-handle-nodes-without-Routes.patch b/media-video/wireplumber/files/wireplumber-0.4.7-default-nodes-handle-nodes-without-Routes.patch
new file mode 100644
index 000000000000..3451ea73f74b
--- /dev/null
+++ b/media-video/wireplumber/files/wireplumber-0.4.7-default-nodes-handle-nodes-without-Routes.patch
@@ -0,0 +1,51 @@
+https://gitlab.freedesktop.org/pipewire/wireplumber/-/commit/211f1e6b6cd4898121e4c2b821fae4dea6cc3317
+https://gitlab.freedesktop.org/pipewire/wireplumber/-/issues/163
+
+From 211f1e6b6cd4898121e4c2b821fae4dea6cc3317 Mon Sep 17 00:00:00 2001
+From: Wim Taymans <wtaymans@redhat.com>
+Date: Fri, 14 Jan 2022 16:28:48 +0100
+Subject: [PATCH] default-nodes: handle nodes without Routes
+
+When a node has not part of any EnumRoute, we must assume it is
+available.
+
+Fixes selection of Pro Audio nodes as default nodes.
+---
+ modules/module-default-nodes.c | 6 ++++++
+ 1 file changed, 6 insertions(+)
+
+diff --git a/modules/module-default-nodes.c b/modules/module-default-nodes.c
+index 32b2725b..15aadeaa 100644
+--- a/modules/module-default-nodes.c
++++ b/modules/module-default-nodes.c
+@@ -108,6 +108,7 @@ node_has_available_routes (WpDefaultNodes * self, WpNode *node)
+ gint dev_id = dev_id_str ? atoi (dev_id_str) : -1;
+ gint cpd = cpd_str ? atoi (cpd_str) : -1;
+ g_autoptr (WpDevice) device = NULL;
++ gint found = 0;
+
+ if (dev_id == -1 || cpd == -1)
+ return TRUE;
+@@ -168,6 +169,7 @@ node_has_available_routes (WpDefaultNodes * self, WpNode *node)
+ for (; wp_iterator_next (it, &v); g_value_unset (&v)) {
+ gint32 *d = (gint32 *)g_value_get_pointer (&v);
+ if (d && *d == cpd) {
++ found++;
+ if (route_avail != SPA_PARAM_AVAILABILITY_no)
+ return TRUE;
+ }
+@@ -175,6 +177,10 @@ node_has_available_routes (WpDefaultNodes * self, WpNode *node)
+ }
+ }
+ }
++ /* The node is part of a profile without routes so we assume it
++ * is available. This can happen for Pro Audio profiles */
++ if (found == 0)
++ return TRUE;
+
+ return FALSE;
+ }
+--
+GitLab
+
+https://gitlab.freedesktop.org/pipewire/wireplumber/-/commit/211f1e6b6cd4898121e4c2b821fae4dea6cc3317
diff --git a/media-video/wireplumber/wireplumber-0.4.6-r1.ebuild b/media-video/wireplumber/wireplumber-0.4.6-r1.ebuild
new file mode 100644
index 000000000000..16b0e2144871
--- /dev/null
+++ b/media-video/wireplumber/wireplumber-0.4.6-r1.ebuild
@@ -0,0 +1,97 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+LUA_COMPAT=( lua5-{3,4} )
+
+inherit lua-single meson systemd
+
+if [[ ${PV} == 9999 ]]; then
+ EGIT_REPO_URI="https://gitlab.freedesktop.org/pipewire/${PN}.git"
+ EGIT_BRANCH="master"
+ inherit git-r3
+else
+ SRC_URI="https://gitlab.freedesktop.org/pipewire/${PN}/-/archive/${PV}/${P}.tar.gz"
+ KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~riscv ~sparc ~x86"
+fi
+
+DESCRIPTION="Replacement for pipewire-media-session"
+HOMEPAGE="https://gitlab.freedesktop.org/pipewire/wireplumber"
+
+LICENSE="MIT"
+SLOT="0/0.4"
+IUSE="elogind systemd test"
+
+REQUIRED_USE="
+ ${LUA_REQUIRED_USE}
+ ?? ( elogind systemd )
+"
+
+RESTRICT="!test? ( test )"
+
+# introspection? ( dev-libs/gobject-introspection ) is valid but likely only used for doc building
+BDEPEND="
+ dev-libs/glib
+ dev-util/gdbus-codegen
+ dev-util/glib-utils
+"
+
+DEPEND="
+ ${LUA_DEPS}
+ >=dev-libs/glib-2.62
+ >=media-video/pipewire-0.3.43:=
+ virtual/libc
+ elogind? ( sys-auth/elogind )
+ systemd? ( sys-apps/systemd )
+"
+
+# Any dev-lua/* deps get declared like this inside RDEPEND:
+# $(lua_gen_cond_dep '
+# dev-lua/<NAME>[${LUA_USEDEP}]
+# ')
+RDEPEND="${DEPEND}"
+
+DOCS=( {NEWS,README}.rst )
+
+PATCHES=(
+ "${FILESDIR}"/${P}-policy-node-fix-typo-when-finding-best-target.patch
+ "${FILESDIR}"/${P}-policy-node-schedule-a-rescan-without-timeout-if-def.patch
+ "${FILESDIR}"/${P}-policy-node-find-best-linkable-if-default-one-cannot.patch
+ "${FILESDIR}"/${P}-spa-pod-fix-different-architecture-errors-for-boolea.patch
+)
+
+src_configure() {
+ local emesonargs=(
+ -Ddoc=disabled # Ebuild not wired up yet (Sphinx, Doxygen?)
+ -Dintrospection=disabled # Only used for Sphinx doc generation
+ -Dsystem-lua=true # We always unbundle everything we can
+ -Dsystem-lua-version=$(ver_cut 1-2 $(lua_get_version))
+ $(meson_feature elogind)
+ $(meson_feature systemd)
+ -Dsystemd-system-service=false # Matches upstream
+ $(meson_use systemd systemd-user-service)
+ -Dsystemd-system-unit-dir=$(systemd_get_systemunitdir)
+ -Dsystemd-user-unit-dir=$(systemd_get_userunitdir)
+ $(meson_use test tests)
+ )
+
+ meson_src_configure
+}
+
+pkg_postinst() {
+ if systemd_is_booted ; then
+ ewarn "pipewire-media-session.service is no longer installed. You must switch"
+ ewarn "to wireplumber.service user unit before your next logout/reboot:"
+ ewarn "systemctl --user disable pipewire-media-session.service"
+ ewarn "systemctl --user --force enable wireplumber.service"
+ else
+ ewarn "Switch to WirePlumber will happen the next time gentoo-pipewire-launcher"
+ ewarn "is started (a replacement for directly calling pipewire binary)."
+ ewarn
+ ewarn "Please ensure that ${EROOT}/etc/pipewire/pipewire.conf either does not exist"
+ ewarn "or, if it does exist, that any reference to"
+ ewarn "${EROOT}/usr/bin/pipewire-media-session is commented out (begins with a #)."
+ fi
+ ewarn
+}
diff --git a/media-video/wireplumber/wireplumber-0.4.6.ebuild b/media-video/wireplumber/wireplumber-0.4.7-r1.ebuild
index 92ffe0cec0a2..a071b5b2b18f 100644
--- a/media-video/wireplumber/wireplumber-0.4.6.ebuild
+++ b/media-video/wireplumber/wireplumber-0.4.7-r1.ebuild
@@ -55,7 +55,7 @@ RDEPEND="${DEPEND}"
DOCS=( {NEWS,README}.rst )
PATCHES=(
- "${FILESDIR}"/${P}-endianness-fixes.patch
+ "${FILESDIR}"/${P}-default-nodes-handle-nodes-without-Routes.patch
)
src_configure() {