Gentoo Archives: gentoo-catalyst

From: Matt Turner <mattst88@g.o>
To: gentoo-catalyst@l.g.o
Cc: Matt Turner <mattst88@g.o>
Subject: [gentoo-catalyst] [PATCH 4/8] targets: Test for locale-gen
Date: Fri, 15 May 2020 06:10:26
Message-Id: 20200515061001.2581484-4-mattst88@gentoo.org
In Reply to: [gentoo-catalyst] [PATCH 1/8] doc: Remove extra asterisk by Matt Turner
1 locale-gen is only provided by glibc and not by others.
2
3 Signed-off-by: Matt Turner <mattst88@g.o>
4 ---
5 targets/stage1/chroot.sh | 4 +++-
6 1 file changed, 3 insertions(+), 1 deletion(-)
7
8 diff --git a/targets/stage1/chroot.sh b/targets/stage1/chroot.sh
9 index ac9d68ea..b48fda65 100755
10 --- a/targets/stage1/chroot.sh
11 +++ b/targets/stage1/chroot.sh
12 @@ -82,7 +82,9 @@ run_merge "--oneshot ${clst_buildpkgs}"
13 # locale-gen does not support the ROOT variable, and as such glibc simply does
14 # not run locale-gen when ROOT is set. Since we've set LANG, we need to run
15 # locale-gen explicitly.
16 -locale-gen --destdir "${clst_root_path}"/ || die "locale-gen failed"
17 +if [ -x "$(command -v locale-gen)" ]; then
18 + locale-gen --destdir "${clst_root_path}"/ || die "locale-gen failed"
19 +fi
20
21 # Why are we removing these? Don't we need them for final make.conf?
22 for useexpand in ${clst_HOSTUSEEXPAND}; do
23 --
24 2.26.2