mirror of
https://github.com/KDE/kde-linux.git
synced 2026-06-14 18:50:21 -04:00
try to use glibc-locales instead of locale-gen
shaves at least 10 minutes off the build time while only costing about 20 mib when installed (even less when compressed)
This commit is contained in:
@@ -5,6 +5,7 @@
|
||||
Packages=archlinux-keyring
|
||||
base
|
||||
btrfs-progs
|
||||
glibc-locales # instead of running locale-gen as part of our build we install a package that has all locales pre-generated
|
||||
kernel-modules-hook
|
||||
kmod
|
||||
linux
|
||||
|
||||
@@ -1,21 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
# SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL
|
||||
# SPDX-FileCopyrightText: 2025 Harald Sitter <sitter@kde.org>
|
||||
|
||||
set -ex
|
||||
|
||||
if [ "$1" = "final" ]; then
|
||||
# Generate all locales. Because /usr/lib is not writable in the target system we need to ship all locales pre-generated.
|
||||
# Sucks. But oh well.
|
||||
# We can at least limit to UTF-8 variants because nobody uses the rest and Qt doesn't even work with them.
|
||||
grep UTF-8 /usr/share/i18n/SUPPORTED > /etc/locale.gen
|
||||
|
||||
# Also allow overriding the list by setting a LOCALE_GEN environment variable
|
||||
# in mkosi.local.conf or command line parameters for local builds
|
||||
if [ -n "$LOCALE_GEN" ]; then
|
||||
echo "$LOCALE_GEN" > /etc/locale.gen
|
||||
fi
|
||||
|
||||
locale-gen
|
||||
fi
|
||||
Reference in New Issue
Block a user