The discussion with Frans de Boer in lfs-support shown that the environment
variables from host can catch us completely off guard. Though in his case the
problem is that he forgot to create /home/lfs/.bash_profile, normally
/etc/bash.bashrc would be more dangerous (the book has no consideration of this
file), and used by many distros.
So if there is no objection I'll commit the change we've discussed in last Nov.:
/home/lfs/.bash_profile:
exec env -i ENV=$HOME/.lfs_bashrc \
HOME=$HOME \
TERM=$TERM \
PS1='\u:\w\$ ' \
/bin/bash --posix
/home/lfs/.lfs_bashrc:
set +o posix
set +h
umask 022
LFS=/mnt/lfs
LC_ALL=POSIX
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
--
Xi Ruoyao <[email protected]>
School of Aerospace Science and Technology, Xidian University
--
http://lists.linuxfromscratch.org/listinfo/lfs-dev
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page