From: sunilkumar.dora@windriver.com
To: openembedded-core@lists.openembedded.org
Cc: raj.khem@gmail.com, randy.macleod@windriver.com,
sundeep.kokkonda@windriver.com, deepesh.vatharaj@windriver.com
Subject: [PATCH 07/11] pango: Don't turn clang 23's -Wunused-but-set-global into an error
Date: Sun, 30 Aug 2026 18:28:47 +0530 [thread overview]
Message-ID: <20260830125853.1139807-8-sunilkumar.dora@windriver.com> (raw)
In-Reply-To: <20260830125853.1139807-1-sunilkumar.dora@windriver.com>
From: Sunil Dora <sunilkumar.dora@windriver.com>
clang 23 added -Wunused-but-set-global to the -Wunused-but-set-variable
group, which pango promotes to an error:
pango/pango-fontset.c:36:1: error: variable 'pango_fontset_parent_class'
set but not used [-Werror,-Wunused-but-set-global]
It fires on the parent_class variables emitted by GLib's G_DEFINE_TYPE
macros. Keep the warning visible but not fatal. gcc builds are
unaffected as meson only passes flags the compiler supports.
Reported upstream with patches attached: the meson change as pango
issue #900 and the underlying GLib macro fix as glib issue #4038.
Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
---
...ror-on-clang-s-unused-but-set-global.patch | 28 +++++++++++++++++++
meta/recipes-graphics/pango/pango_1.58.0.bb | 1 +
2 files changed, 29 insertions(+)
create mode 100644 meta/recipes-graphics/pango/pango/0001-meson-don-t-error-on-clang-s-unused-but-set-global.patch
diff --git a/meta/recipes-graphics/pango/pango/0001-meson-don-t-error-on-clang-s-unused-but-set-global.patch b/meta/recipes-graphics/pango/pango/0001-meson-don-t-error-on-clang-s-unused-but-set-global.patch
new file mode 100644
index 0000000000..2c3788abdf
--- /dev/null
+++ b/meta/recipes-graphics/pango/pango/0001-meson-don-t-error-on-clang-s-unused-but-set-global.patch
@@ -0,0 +1,28 @@
+From: Sunil Dora <sunilkumar.dora@windriver.com>
+Date: Wed, 20 Aug 2026 10:45:00 +0530
+Subject: [PATCH] meson: don't error on clang's -Wunused-but-set-global
+
+clang 23 added -Wunused-but-set-global to the -Wunused-but-set-variable
+group, so the -Werror=unused-but-set-variable in test_cflags now turns
+it into an error. It fires on the <type>_parent_class variables that
+GLib's G_DEFINE_TYPE family of macros emit, which pango cannot fix, and
+on a few deliberately write-only globals in the test suite.
+
+Keep the warning visible but not fatal. gcc does not know this warning
+group, so cc.get_supported_arguments() drops the flag there.
+
+Upstream-Status: Submitted [https://gitlab.gnome.org/GNOME/pango/-/issues/900]
+Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
+---
+--- a/meson.build
++++ b/meson.build
+@@ -148,6 +148,9 @@
+ '-Werror=empty-body',
+ '-Werror=write-strings',
+ '-Werror=unused-but-set-variable',
++ # clang 23 made this part of the group above; it fires on GLib's
++ # G_DEFINE_TYPE boilerplate, which pango cannot fix.
++ '-Wno-error=unused-but-set-global',
+ '-Wundef', # FIXME: https://bugzilla.gnome.org/show_bug.cgi?id=792481
+ ]
+
diff --git a/meta/recipes-graphics/pango/pango_1.58.0.bb b/meta/recipes-graphics/pango/pango_1.58.0.bb
index 6e1aebad1d..0c9e26f39c 100644
--- a/meta/recipes-graphics/pango/pango_1.58.0.bb
+++ b/meta/recipes-graphics/pango/pango_1.58.0.bb
@@ -18,6 +18,7 @@ UPSTREAM_CHECK_REGEX = "pango-(?P<pver>\d+\.(?!9\d+)\d+\.\d+)"
GIR_MESON_ENABLE_FLAG = "enabled"
GIR_MESON_DISABLE_FLAG = "disabled"
+SRC_URI += "file://0001-meson-don-t-error-on-clang-s-unused-but-set-global.patch"
SRC_URI[archive.sha256sum] = "bc5bad6213ad4886a47d1e80292fd850b64159b50db67917a43d9ea80ee2298a"
DEPENDS = "glib-2.0 glib-2.0-native fontconfig freetype virtual/libiconv cairo harfbuzz fribidi"
--
2.43.0
next prev parent reply other threads:[~2026-08-30 12:59 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-30 12:58 [PATCH 00/11] clang/llvm: Upgrade to 23.1.0 sunilkumar.dora
2026-08-30 12:58 ` [PATCH 01/11] clang/llvm: Upgrade to 23.1.0 release sunilkumar.dora
2026-08-30 19:53 ` Khem Raj
2026-09-01 3:37 ` [OE-core] " Dora, Sunil Kumar
2026-09-01 12:49 ` Richard Purdie
2026-08-30 12:58 ` [PATCH 02/11] spirv-llvm-translator: Upgrade to 23.1.0 sunilkumar.dora
2026-08-30 19:43 ` Khem Raj
2026-09-01 4:07 ` [OE-core] " Dora, Sunil Kumar
2026-08-30 12:58 ` [PATCH 03/11] openmp: Build via the LLVM runtimes entry point sunilkumar.dora
2026-08-30 19:45 ` Khem Raj
2026-09-01 4:33 ` [OE-core] " Dora, Sunil Kumar
2026-09-03 1:11 ` Khem Raj
2026-08-30 12:58 ` [PATCH 04/11] rust: Fix build and oe-selftest failures with LLVM 23 sunilkumar.dora
2026-08-30 19:47 ` Khem Raj
2026-09-01 5:17 ` [OE-core] " Dora, Sunil Kumar
2026-09-03 1:08 ` Khem Raj
2026-08-30 12:58 ` [PATCH 05/11] rust: Do not pass the removed x86 amx-tf32 feature to " sunilkumar.dora
2026-08-30 12:58 ` [PATCH 06/11] clang: Disable clangd's decision-forest completion model on powerpc sunilkumar.dora
2026-08-30 12:58 ` sunilkumar.dora [this message]
2026-08-30 12:58 ` [PATCH 08/11] ovmf: Fix memcpy alias prototype for clang 23 sunilkumar.dora
2026-08-30 12:58 ` [PATCH 09/11] vulkan-samples: Don't turn clang 23's -Wdangling-gsl into an error sunilkumar.dora
2026-08-30 12:58 ` [PATCH 10/11] gettext: Export a fully-flagged Objective-C compiler sunilkumar.dora
2026-08-30 12:58 ` [PATCH 11/11] clang/llvm: Ignore tests fail with clang/llvm 23 upgrade sunilkumar.dora
2026-08-30 19:53 ` [PATCH 00/11] clang/llvm: Upgrade to 23.1.0 Khem Raj
2026-09-01 4:59 ` [OE-core] " Dora, Sunil Kumar
2026-09-03 1:10 ` Khem Raj
2026-09-03 23:46 ` Khem Raj
2026-09-04 4:49 ` Dora, Sunil Kumar
2026-09-05 13:26 ` Dora, Sunil Kumar
2026-09-05 18:01 ` [OE-core] " Khem Raj
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260830125853.1139807-8-sunilkumar.dora@windriver.com \
--to=sunilkumar.dora@windriver.com \
--cc=deepesh.vatharaj@windriver.com \
--cc=openembedded-core@lists.openembedded.org \
--cc=raj.khem@gmail.com \
--cc=randy.macleod@windriver.com \
--cc=sundeep.kokkonda@windriver.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.