Git-Url: 
http://git.frugalware.org/gitweb/gitweb.cgi?p=fwlive.git;a=commitdiff;h=5b0094090980e8d5fb5b64e00c03d32779f68bcc

commit 5b0094090980e8d5fb5b64e00c03d32779f68bcc
Author: Baste <ba...@frugalware.org>
Date:   Sat Dec 3 14:51:21 2011 +0100

* Added a test to ensure there is only one mount $CHROOTDIR

diff --git a/bin/create-rootfs b/bin/create-rootfs
index 04401e2..5f906ed 100755
--- a/bin/create-rootfs
+++ b/bin/create-rootfs
@@ -7,6 +7,14 @@ if [ "`id -u`" != 0 ]; then
echo "Building the chroot as an unprivileged user is not possible."
exit 1
fi
+
+if [ `mount|grep -o $CHROOTDIR/var/cache/pacman-g2` ]; then
+       umount -f $CHROOTDIR/proc
+       umount -f $CHROOTDIR/sys
+       umount -f $CHROOTDIR/var/cache/pacman-g2
+       umount -f $CHROOTDIR
+fi
+
## Check package needs for build
if [ "`pacman-g2 -Q squashfs &>/dev/null;echo $?`" != 0 ]; then
echo "Installing Squashfs"
_______________________________________________
Frugalware-git mailing list
Frugalware-git@frugalware.org
http://frugalware.org/mailman/listinfo/frugalware-git

Reply via email to