Reorder code for "/etc/mtab"
This commit is contained in:
parent
bc394942d0
commit
7428aca587
1 changed files with 5 additions and 2 deletions
7
build.sh
7
build.sh
|
@ -158,6 +158,11 @@ mount --bind /dev/pts "$ROOTFS_DIR/dev/pts"
|
|||
mount -t proc /proc "$ROOTFS_DIR/proc"
|
||||
mount --bind /sys "$ROOTFS_DIR/sys"
|
||||
|
||||
##
|
||||
# Add /etc/mtab
|
||||
#
|
||||
ln -nsf /proc/mounts "$ROOTFS_DIR/etc/mtab"
|
||||
|
||||
##
|
||||
# Prevent services to start after package installation in chroot environment.
|
||||
#
|
||||
|
@ -411,8 +416,6 @@ rm -f "$MOUNT_DIR/var/lib/dpkg/*-old"
|
|||
|
||||
rm -f "$MOUNT_DIR/usr/share/icons/*/icon-theme.cache"
|
||||
|
||||
ln -nsf /proc/mounts "$MOUNT_DIR/etc/mtab"
|
||||
|
||||
for _FILE in $(find "$MOUNT_DIR/var/log/" -type f); do
|
||||
true > "$_FILE"
|
||||
done
|
||||
|
|
Reference in a new issue