Gentoo Archives: gentoo-commits

From: Matt Turner <mattst88@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: scripts/
Date: Mon, 30 Mar 2020 01:38:01
Message-Id: 1585532270.0aa49828ae253a22a3327f4024fcada801e64245.mattst88@gentoo
1 commit: 0aa49828ae253a22a3327f4024fcada801e64245
2 Author: Matt Turner <mattst88 <AT> gentoo <DOT> org>
3 AuthorDate: Mon Mar 30 01:15:25 2020 +0000
4 Commit: Matt Turner <mattst88 <AT> gentoo <DOT> org>
5 CommitDate: Mon Mar 30 01:37:50 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0aa49828
7
8 scripts/bootstrap.sh: Allow CONFIG_PROTECT
9
10 With a CONFIG_PROTECT="-*" setting, glibc will overwrite the system's
11 /etc/locale.gen file in src_install() with its default-empty one. In
12 pkg_postinst() it reads the empty /etc/locale.gen it just installed, and
13 as a result generates all locales.
14
15 So, allow CONFIG_PROTECT to be passed through unmolested so long as it
16 starts with "-*". This allows locales to be selectively enabled when
17 bootstrap.sh is run with CONFIG_PROTECT="-* /etc/locale.gen".
18
19 Signed-off-by: Matt Turner <mattst88 <AT> gentoo.org>
20
21 scripts/bootstrap.sh | 2 +-
22 1 file changed, 1 insertion(+), 1 deletion(-)
23
24 diff --git a/scripts/bootstrap.sh b/scripts/bootstrap.sh
25 index aa31fb15e8b..c06e25dba13 100755
26 --- a/scripts/bootstrap.sh
27 +++ b/scripts/bootstrap.sh
28 @@ -306,7 +306,7 @@ echo ---------------------------------------------------------------------------
29 [[ -x /usr/bin/gcc-config ]] && GCC_CONFIG="/usr/bin/gcc-config"
30
31 # Allow portage to overwrite stuff
32 -export CONFIG_PROTECT="-*"
33 +[[ $CONFIG_PROTECT != "-*"* ]] && export CONFIG_PROTECT="-*"
34
35 # disable collision-protection
36 export FEATURES="${FEATURES} -collision-protect"