* [gentoo-dev] [PATCH] chromium-2.eclass: Handle non-standard _ suffixes in locale .pak files
@ 2025-08-23 20:12 James Le Cuirot
2025-08-26 22:01 ` [gentoo-dev] " Matt Jolly
0 siblings, 1 reply; 2+ messages in thread
From: James Le Cuirot @ 2025-08-23 20:12 UTC (permalink / raw
To: gentoo-dev; +Cc: Chromium Project, James Le Cuirot
These were recently added by Chromium for gender-based translations. _
is not a valid language tag character, so we strip this suffix when
checking the USE flag, thereby grouping such files with their
non-suffixed counterparts.
Signed-off-by: James Le Cuirot <chewi@gentoo.org>
---
eclass/chromium-2.eclass | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/eclass/chromium-2.eclass b/eclass/chromium-2.eclass
index e8f471e2178f4..f1f5b3a7b35ac 100644
--- a/eclass/chromium-2.eclass
+++ b/eclass/chromium-2.eclass
@@ -78,7 +78,7 @@ fi
# not selected via the L10N variable.
# Also performs QA checks to ensure CHROMIUM_LANGS has been set correctly.
chromium_remove_language_paks() {
- local lang pak
+ local lang pak suffixed
# Look for missing pak files.
for lang in ${CHROMIUM_LANGS}; do
@@ -93,8 +93,12 @@ chromium_remove_language_paks() {
# Look for extra pak files.
# Remove pak files that the user does not want.
+ # Chromium includes pak files with non-standard _ suffixes. _ is not a valid
+ # language tag character, so we strip this suffix when checking the USE
+ # flag, thereby grouping such files with their non-suffixed counterparts.
for pak in *.pak; do
- lang=${pak%.pak}
+ suffixed=${pak%.pak}
+ lang=${suffixed%%_*}
if [[ ${lang} == en-US ]]; then
continue
--
2.50.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [gentoo-dev] Re: [PATCH] chromium-2.eclass: Handle non-standard _ suffixes in locale .pak files
2025-08-23 20:12 [gentoo-dev] [PATCH] chromium-2.eclass: Handle non-standard _ suffixes in locale .pak files James Le Cuirot
@ 2025-08-26 22:01 ` Matt Jolly
0 siblings, 0 replies; 2+ messages in thread
From: Matt Jolly @ 2025-08-26 22:01 UTC (permalink / raw
To: James Le Cuirot, gentoo-dev; +Cc: Chromium Project
LGTM. Thanks for taking this on.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2025-08-26 22:02 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-23 20:12 [gentoo-dev] [PATCH] chromium-2.eclass: Handle non-standard _ suffixes in locale .pak files James Le Cuirot
2025-08-26 22:01 ` [gentoo-dev] " Matt Jolly
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox