mirror of
https://github.com/openembedded/meta-openembedded.git
synced 2026-07-26 19:47:17 +00:00
pavucontrol: update; fix build for wayland only
- Update to v5.0 - Add a patch for wayland builds that removes canberra dependency. Since the canberra-gtk+3 module paradoxically depends on gtk+2 it is unbuildable for wayland. Signed-off-by: Markus Volk <f_l_k@t-online.de> Signed-off-by: Khem Raj <raj.khem@gmail.com>
This commit is contained in:
+112
@@ -0,0 +1,112 @@
|
|||||||
|
From 87992a57e5f517d5ceb5dfabaea662ac64983720 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Markus Volk <f_l_k@t-online.de>
|
||||||
|
Date: Fri, 27 May 2022 18:37:53 +0200
|
||||||
|
Subject: [PATCH] pavucontrol: remove canberra-gtk support
|
||||||
|
|
||||||
|
libcanberra-gtk3 module isn't buildable for wayland.
|
||||||
|
Remove its dpendency.
|
||||||
|
|
||||||
|
Signed-off-by: Markus Volk <f_l_k@t-online.de>
|
||||||
|
|
||||||
|
Upstream-Status: Inappropriate
|
||||||
|
---
|
||||||
|
configure.ac | 2 +-
|
||||||
|
src/pavuapplication.cc | 2 --
|
||||||
|
src/pavucontrol.cc | 4 ----
|
||||||
|
src/sinkwidget.cc | 17 -----------------
|
||||||
|
4 files changed, 1 insertion(+), 24 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/configure.ac b/configure.ac
|
||||||
|
index 056ba5e..e857563 100644
|
||||||
|
--- a/configure.ac
|
||||||
|
+++ b/configure.ac
|
||||||
|
@@ -41,7 +41,7 @@ AC_TYPE_SIGNAL
|
||||||
|
AC_HEADER_STDC
|
||||||
|
AX_CXX_COMPILE_STDCXX_11
|
||||||
|
|
||||||
|
-PKG_CHECK_MODULES(GUILIBS, [ gtkmm-3.0 >= 3.22 sigc++-2.0 libcanberra-gtk3 >= 0.16 json-glib-1.0 ])
|
||||||
|
+PKG_CHECK_MODULES(GUILIBS, [ gtkmm-3.0 >= 3.22 sigc++-2.0 json-glib-1.0 ])
|
||||||
|
AC_SUBST(GUILIBS_CFLAGS)
|
||||||
|
AC_SUBST(GUILIBS_LIBS)
|
||||||
|
|
||||||
|
diff --git a/src/pavuapplication.cc b/src/pavuapplication.cc
|
||||||
|
index 6773b53..60c016c 100644
|
||||||
|
--- a/src/pavuapplication.cc
|
||||||
|
+++ b/src/pavuapplication.cc
|
||||||
|
@@ -24,8 +24,6 @@
|
||||||
|
|
||||||
|
#include "i18n.h"
|
||||||
|
|
||||||
|
-#include <canberra-gtk.h>
|
||||||
|
-
|
||||||
|
#include "pavuapplication.h"
|
||||||
|
#include "pavucontrol.h"
|
||||||
|
#include "mainwindow.h"
|
||||||
|
diff --git a/src/pavucontrol.cc b/src/pavucontrol.cc
|
||||||
|
index 18d5400..10ab646 100644
|
||||||
|
--- a/src/pavucontrol.cc
|
||||||
|
+++ b/src/pavucontrol.cc
|
||||||
|
@@ -29,8 +29,6 @@
|
||||||
|
#include <json-glib/json-glib.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
-#include <canberra-gtk.h>
|
||||||
|
-
|
||||||
|
#include "pavucontrol.h"
|
||||||
|
#include "i18n.h"
|
||||||
|
#include "minimalstreamwidget.h"
|
||||||
|
@@ -916,8 +914,6 @@ MainWindow* pavucontrol_get_window(pa_glib_mainloop *m, bool maximize, bool _ret
|
||||||
|
tab_number = _tab_number;
|
||||||
|
retry = _retry;
|
||||||
|
|
||||||
|
- ca_context_set_driver(ca_gtk_context_get(), "pulse");
|
||||||
|
-
|
||||||
|
mainWindow = MainWindow::create(maximize);
|
||||||
|
|
||||||
|
api = pa_glib_mainloop_get_api(m);
|
||||||
|
diff --git a/src/sinkwidget.cc b/src/sinkwidget.cc
|
||||||
|
index f30bd37..482fd1f 100644
|
||||||
|
--- a/src/sinkwidget.cc
|
||||||
|
+++ b/src/sinkwidget.cc
|
||||||
|
@@ -24,7 +24,6 @@
|
||||||
|
|
||||||
|
#include "sinkwidget.h"
|
||||||
|
|
||||||
|
-#include <canberra-gtk.h>
|
||||||
|
#if HAVE_EXT_DEVICE_RESTORE_API
|
||||||
|
# include <pulse/format.h>
|
||||||
|
# include <pulse/ext-device-restore.h>
|
||||||
|
@@ -111,7 +110,6 @@ SinkWidget* SinkWidget::create(MainWindow* mainWindow) {
|
||||||
|
void SinkWidget::executeVolumeUpdate() {
|
||||||
|
pa_operation* o;
|
||||||
|
char dev[64];
|
||||||
|
- int playing = 0;
|
||||||
|
|
||||||
|
if (!(o = pa_context_set_sink_volume_by_index(get_context(), index, &volume, NULL, NULL))) {
|
||||||
|
show_error(_("pa_context_set_sink_volume_by_index() failed"));
|
||||||
|
@@ -120,22 +118,7 @@ void SinkWidget::executeVolumeUpdate() {
|
||||||
|
|
||||||
|
pa_operation_unref(o);
|
||||||
|
|
||||||
|
- ca_context_playing(ca_gtk_context_get(), 2, &playing);
|
||||||
|
- if (playing)
|
||||||
|
- return;
|
||||||
|
-
|
||||||
|
snprintf(dev, sizeof(dev), "%lu", (unsigned long) index);
|
||||||
|
- ca_context_change_device(ca_gtk_context_get(), dev);
|
||||||
|
-
|
||||||
|
- ca_gtk_play_for_widget(GTK_WIDGET(gobj()),
|
||||||
|
- 2,
|
||||||
|
- CA_PROP_EVENT_DESCRIPTION, _("Volume Control Feedback Sound"),
|
||||||
|
- CA_PROP_EVENT_ID, "audio-volume-change",
|
||||||
|
- CA_PROP_CANBERRA_CACHE_CONTROL, "permanent",
|
||||||
|
- CA_PROP_CANBERRA_ENABLE, "1",
|
||||||
|
- NULL);
|
||||||
|
-
|
||||||
|
- ca_context_change_device(ca_gtk_context_get(), NULL);
|
||||||
|
}
|
||||||
|
|
||||||
|
void SinkWidget::onMuteToggleButton() {
|
||||||
|
--
|
||||||
|
2.25.1
|
||||||
|
|
||||||
+9
-6
@@ -8,16 +8,19 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=751419260aa954499f7abaabaa882bbe"
|
|||||||
# AM_GLIB_GNU_GETTEXT macro in configure.ac. That macro is deprecated, so the
|
# AM_GLIB_GNU_GETTEXT macro in configure.ac. That macro is deprecated, so the
|
||||||
# glib-2.0-native dependency may go away at some point (something to keep in
|
# glib-2.0-native dependency may go away at some point (something to keep in
|
||||||
# mind when doing version upgrades).
|
# mind when doing version upgrades).
|
||||||
DEPENDS = "libxml-parser-perl-native intltool-native glib-2.0-native gtkmm3 libcanberra pulseaudio"
|
DEPENDS = "libxml-parser-perl-native intltool-native glib-2.0-native gtkmm3 pulseaudio json-glib"
|
||||||
|
|
||||||
inherit autotools features_check perlnative pkgconfig
|
inherit autotools features_check perlnative pkgconfig
|
||||||
|
|
||||||
REQUIRED_DISTRO_FEATURES = "x11"
|
ANY_OF_DISTRO_FEATURES = "${GTK3DISTROFEATURES}"
|
||||||
|
|
||||||
SRC_URI = "http://freedesktop.org/software/pulseaudio/${BPN}/${BP}.tar.xz \
|
SRC_URI = "http://freedesktop.org/software/pulseaudio/${BPN}/${BP}.tar.xz"
|
||||||
"
|
SRC_URI:append = " ${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'file://0001-pavucontrol-remove-canberra-gtk-support.patch', '', d)}"
|
||||||
SRC_URI[md5sum] = "9dcc2c76292e7e5e075d51b8dcb20202"
|
|
||||||
SRC_URI[sha256sum] = "8fc45bac9722aefa6f022999cbb76242d143c31b314e2dbb38f034f4069d14e2"
|
SRC_URI[sha256sum] = "ce2b72c3b5f1a70ad0df19dd81750f9455bd20870d1d3a36d20536af2e8f4e7a"
|
||||||
|
|
||||||
|
PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)}"
|
||||||
|
PACKAGECONFIG[x11] = ",,libcanberra"
|
||||||
|
|
||||||
EXTRA_OECONF = "--disable-lynx "
|
EXTRA_OECONF = "--disable-lynx "
|
||||||
|
|
||||||
Reference in New Issue
Block a user