From df77b24d1d42c619e443d37c9fe04b62ac094855 Mon Sep 17 00:00:00 2001 From: Xi Ruoyao Date: Fri, 4 Sep 2020 07:38:44 +0000 Subject: [PATCH] env: set CONFIG_SITE to prevent potential contamination from host distro git-svn-id: http://svn.linuxfromscratch.org/LFS/trunk/BOOK@12045 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689 --- chapter04/settingenviron.xml | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/chapter04/settingenviron.xml b/chapter04/settingenviron.xml index b8939be45..7b7809c95 100644 --- a/chapter04/settingenviron.xml +++ b/chapter04/settingenviron.xml @@ -46,7 +46,8 @@ LFS_TGT=$(uname -m)-lfs-linux-gnu PATH=/usr/bin if [ ! -L /bin ]; then PATH=/bin:$PATH; fi PATH=$LFS/tools/bin:$PATH -export LFS LC_ALL LFS_TGT PATH +CONFIG_SITE=$LFS/usr/share/config.site +export LFS LC_ALL LFS_TGT PATH CONFIG_SITE EOF @@ -144,7 +145,19 @@ EOF - export LFS LC_ALL LFS_TGT PATH + CONFIG_SITE=$LFS/usr/share/config.site + + In and + , if this variable is not set, + configure scripts + will attempt to load configuration from + /usr/share/config.site of the host system. Override + it to prevent potential contamination from host. + + + + + export ... While the above commands have set some variables, in order to make them visible within any sub-shells, we export them.