1 |
On Sun, Mar 29, 2020 at 8:26 PM Matt Turner <mattst88@g.o> wrote: |
2 |
|
3 |
> Stable glibc now always provides a UTF-8 capable locale, which many |
4 |
> packages require. Set this as the default LANG. |
5 |
> |
6 |
> Running locale-gen in stage1 should also solve bug #536938. |
7 |
> |
8 |
> Bug: https://bugs.gentoo.org/536938 |
9 |
> Bug: https://bugs.gentoo.org/710762 |
10 |
> Bug: https://bugs.gentoo.org/714906 |
11 |
> Signed-off-by: Matt Turner <mattst88@g.o> |
12 |
> --- |
13 |
> targets/stage1/chroot.sh | 12 ++++++++++++ |
14 |
> 1 file changed, 12 insertions(+) |
15 |
> |
16 |
> diff --git a/targets/stage1/chroot.sh b/targets/stage1/chroot.sh |
17 |
> index 0caf49ee..88a36481 100755 |
18 |
> --- a/targets/stage1/chroot.sh |
19 |
> +++ b/targets/stage1/chroot.sh |
20 |
> @@ -57,6 +57,11 @@ make_destpath /tmp/stage1root |
21 |
> run_merge "--oneshot --nodeps sys-apps/baselayout" |
22 |
> ${clst_sed} -i "/USE=\"${USE} -build\"/d" ${clst_make_conf} |
23 |
> |
24 |
> +for etc in /etc /tmp/stage1root/etc; do |
25 |
> + echo "LANG=C.UTF8" > ${etc}/env.d/02locale |
26 |
> +done |
27 |
> +update_env_settings |
28 |
> + |
29 |
> |
30 |
|
31 |
if /tmp/stage1root is "${clst_root_path}" I think it might behoove you to |
32 |
use it here rather than hard coding it. |
33 |
Same as below. |
34 |
|
35 |
# Now, we install our packages |
36 |
> if [ -e ${clst_make_conf} ]; then |
37 |
> echo "CATALYST_USE=\"-* build ${BINDIST} ${clst_CATALYST_USE}\"" |
38 |
> >> ${clst_make_conf} |
39 |
> @@ -71,6 +76,13 @@ fi |
40 |
> |
41 |
> run_merge "--oneshot ${clst_buildpkgs}" |
42 |
> |
43 |
> +# TODO: Drop this when locale-gen in stable glibc supports ROOT. |
44 |
> +# |
45 |
> +# locale-gen does not support the ROOT variable, and as such glibc simply |
46 |
> does |
47 |
> +# not run locale-gen when ROOT is set. Since we've set LANG, we need to |
48 |
> run |
49 |
> +# locale-gen explicitly. |
50 |
> +locale-gen --destdir /tmp/stage1root/ |
51 |
> + |
52 |
> # Why are we removing these? Don't we need them for final make.conf? |
53 |
> for useexpand in ${clst_HOSTUSEEXPAND}; do |
54 |
> x="clst_${useexpand}" |
55 |
> -- |
56 |
> 2.24.1 |
57 |
> |
58 |
> |
59 |
> |