24 lines
572 B
Bash
24 lines
572 B
Bash
#!/bin/bash
|
|
|
|
source vars.sh
|
|
|
|
mount -v --bind /dev $LFS/dev &&
|
|
mount -v --bind /dev/pts $LFS/dev/pts &&
|
|
mount -vt proc proc $LFS/proc &&
|
|
mount -vt sysfs sysfs $LFS/sys &&
|
|
mount -vt tmpfs tmpfs $LFS/run &&
|
|
if [ -h $LFS/dev/shm ]; then
|
|
mkdir -pv $LFS/$(readlink $LFS/dev/shm)
|
|
else
|
|
mount -t tmpfs -o nosuid,nodev tmpfs $LFS/dev/shm
|
|
fi
|
|
|
|
echo "Entering now the chroot environment"
|
|
|
|
chroot "$LFS" /usr/bin/env -i \
|
|
HOME=/root \
|
|
TERM="$TERM" \
|
|
PS1='(lfs chroot) \u:\w\$ ' \
|
|
PATH=/usr/bin:/usr/sbin \
|
|
/bin/bash --login
|