summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEli Schwartz <eschwartz@gentoo.org>2024-07-07 18:41:13 -0400
committerEli Schwartz <eschwartz@gentoo.org>2024-07-07 23:18:39 -0400
commit13e7cc29573344822488e3bb78f798b99ef97688 (patch)
tree06039ff5a17db0f0188fd4891199b8d489d6151c /gnome-base
parentmedia-libs/flac: make sure elibtoolize is applied (diff)
downloadgentoo-13e7cc29573344822488e3bb78f798b99ef97688.tar.gz
gentoo-13e7cc29573344822488e3bb78f798b99ef97688.tar.bz2
gentoo-13e7cc29573344822488e3bb78f798b99ef97688.zip
gnome-base/gnome-shell: backport fix for strict-aliasing with USE=pipewire
Closes: https://bugs.gentoo.org/919853 Signed-off-by: Eli Schwartz <eschwartz@gentoo.org>
Diffstat (limited to 'gnome-base')
-rw-r--r--gnome-base/gnome-shell/files/37e49e8a22c223b030297f9607bdb748c219e060.patch42
-rw-r--r--gnome-base/gnome-shell/gnome-shell-45.6-r1.ebuild (renamed from gnome-base/gnome-shell/gnome-shell-45.6.ebuild)2
2 files changed, 44 insertions, 0 deletions
diff --git a/gnome-base/gnome-shell/files/37e49e8a22c223b030297f9607bdb748c219e060.patch b/gnome-base/gnome-shell/files/37e49e8a22c223b030297f9607bdb748c219e060.patch
new file mode 100644
index 000000000000..d56db89bbacd
--- /dev/null
+++ b/gnome-base/gnome-shell/files/37e49e8a22c223b030297f9607bdb748c219e060.patch
@@ -0,0 +1,42 @@
+From 37e49e8a22c223b030297f9607bdb748c219e060 Mon Sep 17 00:00:00 2001
+From: Philip Withnall <pwithnall@gnome.org>
+Date: Tue, 28 May 2024 18:08:27 +0100
+Subject: [PATCH] shell-camera-monitor: Fix warning about strict aliasing
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Changing type when casting a double pointer is not strictly allowed in
+C. In order to fix compilation with `-fstrict-aliasing`, don’t use
+`g_clear_pointer()` for clearing this pointer where the type expected by
+the destroy notify function does not match the type stored in the
+`ShellCameraMonitor` struct.
+
+This introduces no functional changes.
+
+Signed-off-by: Philip Withnall <pwithnall@gnome.org>
+Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3351>
+---
+ src/shell-camera-monitor.c | 6 +++++-
+ 1 file changed, 5 insertions(+), 1 deletion(-)
+
+diff --git a/src/shell-camera-monitor.c b/src/shell-camera-monitor.c
+index 1e2e0f14569..b2e6e0b2af2 100644
+--- a/src/shell-camera-monitor.c
++++ b/src/shell-camera-monitor.c
+@@ -298,7 +298,11 @@ shell_camera_monitor_disconnect_core (ShellCameraMonitor *monitor)
+ g_clear_handle_id (&monitor->delayed_disable_id, g_source_remove);
+
+ spa_hook_remove (&monitor->registry_listener);
+- g_clear_pointer ((struct pw_proxy**) &monitor->registry, pw_proxy_destroy);
++ if (monitor->registry != NULL)
++ {
++ pw_proxy_destroy ((struct pw_proxy *) monitor->registry);
++ monitor->registry = NULL;
++ }
+ spa_hook_remove (&monitor->core_listener);
+ g_clear_pointer (&monitor->core, pw_core_disconnect);
+ }
+--
+GitLab
+
diff --git a/gnome-base/gnome-shell/gnome-shell-45.6.ebuild b/gnome-base/gnome-shell/gnome-shell-45.6-r1.ebuild
index 92b6670d0970..c9c3acd73caa 100644
--- a/gnome-base/gnome-shell/gnome-shell-45.6.ebuild
+++ b/gnome-base/gnome-shell/gnome-shell-45.6-r1.ebuild
@@ -134,6 +134,8 @@ BDEPEND="
PATCHES=(
# Change favorites defaults, bug #479918
"${FILESDIR}"/40.0-defaults.patch
+ # backport fix for strict-aliasing violation with USE=pipewire
+ "${FILESDIR}"/37e49e8a22c223b030297f9607bdb748c219e060.patch
)
src_prepare() {