Commit 75d1dcbc authored by Vladimir Bashkirtsev's avatar Vladimir Bashkirtsev

We should use bind mounted /home /root /var instead of symlinks during build

parent 21b7dd10
......@@ -49,17 +49,23 @@ $(PACKAGES):
mount -t proc /proc mnt/proc
mount -t sysfs /sysfs mnt/sys
mount -t tmpfs /tmp mnt/tmp
mount -t tmpfs /tmp mnt/var/tmp
mount /dev/$(SECONDARY)1 mnt/build
if [ -d mnt/data ] ; then \
mount /dev/$(DISK)4 mnt/data ; \
mount --bind mnt/data/home mnt/home ; \
mount --bind mnt/data/root mnt/root ; \
mount --bind mnt/data/var mnt/var ; \
fi
mount -t tmpfs /tmp mnt/var/tmp
mount /dev/$(SECONDARY)1 mnt/build
chroot mnt $(MAKE) -C $(current_dir)$(firstword $(subst ., ,$@)) $(word 2, $(subst ., ,$@))
umount -l mnt/var/tmp
if [ -d mnt/data ] && [[ $$(findmnt -M mnt/data) ]] ; then \
umount -l mnt/var ; \
umount -l mnt/root ; \
umount -l mnt/home ; \
umount -l mnt/data ; \
fi
umount -l mnt/build
umount -l mnt/var/tmp
umount -l mnt/tmp
umount -l mnt/sys
umount -l mnt/proc
......
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment