Openembedded Core Discussions
 help / color / mirror / Atom feed
From: Richard Purdie <richard.purdie@linuxfoundation.org>
To: openembedded-core@lists.openembedded.org
Subject: [PATCH 1/4] site/common-glibc: Set gnulib locale variables
Date: Fri, 18 Sep 2026 18:20:28 +0100	[thread overview]
Message-ID: <20260918172031.2871246-1-richard.purdie@linuxfoundation.org> (raw)

These locale variables are determined by running test binaries. Our sysroots
don't really set up locales properly and the results vary depending on the
host architecture and the locales installed.

Fix the values to a known set of locales that could be installed if the
user does so which is at least determinsitic. These are selected so the m4
recipe ptests run successfully.

An extra mbrtoc32 macro needs to also be set to have zh_CN work correctly on target.

We still need the musl equivalent to this.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
 meta/site/common-glibc | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/meta/site/common-glibc b/meta/site/common-glibc
index 29f96da48d6..4dbfb4cb57f 100644
--- a/meta/site/common-glibc
+++ b/meta/site/common-glibc
@@ -67,9 +67,19 @@ gl_cv_func_mbrtowc_sanitycheck=${gl_cv_func_mbrtowc_sanitycheck=yes}
 gl_cv_func_mbrtowc_null_arg=${gl_cv_func_mbrtowc_null_arg=yes}
 gl_cv_func_mbrtowc_retval=${gl_cv_func_mbrtowc_retval=yes}
 gl_cv_func_mbrtowc_nul_retval=${gl_cv_func_mbrtowc_nul_retval=yes}
+gl_cv_func_mbrtoc32_utf8_locale_works=yes
 
 # va_copy and _va_copy
 ac_cv_va_copy=${ac_cv_va_copy=yes}
 ac_cv___va_copy=${ac_cv___va_copy=yes}
 ac_cv_func_va_copy=${ac_cv_func_va_copy=yes}
 ac_cv_func___va_copy=${ac_cv_func___va_copy=yes}
+
+# gnulib locale-en.m4 and friends look at the sysroot or host locales
+# we need something deterministic
+gt_cv_locale_en_utf8=en_US.UTF-8
+gt_cv_locale_fr=fr_FR.iso88591
+gt_cv_locale_fr_utf8=fr_FR.UTF-8
+gt_cv_locale_zh_CN=zh_CN.GB18030
+gt_cv_locale_ja=ja_JP.euc_jp
+gt_cv_locale_tr_utf8=tr_TR.UTF-8


             reply	other threads:[~2026-09-18 17:20 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-18 17:20 Richard Purdie [this message]
2026-09-18 17:20 ` [PATCH 2/4] m4: Add missing ptest locale dependencies Richard Purdie
2026-09-18 17:20 ` [PATCH 3/4] coreutils: Add missing locale ptest dependencies Richard Purdie
2026-09-18 17:20 ` [PATCH 4/4] gettext: Add missing locale ptest dependency Richard Purdie

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=20260918172031.2871246-1-richard.purdie@linuxfoundation.org \
    --to=richard.purdie@linuxfoundation.org \
    --cc=openembedded-core@lists.openembedded.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox