On Thu, Oct 16, 2008 at 8:16 AM, Jeremy Huntwork
<[EMAIL PROTECTED]> wrote:
>
> The real issue is that the --bind mount of /dev is unmounted as are
> /proc and /sys. (BTW, this issue would also affect any attempt to use
> the grub installed in chroot, since that needs the devices corresponding
> to your HDs available.) So maybe the better option is to allow a user to
> specify if they don't want those filesystem's unmounted. Of course you'd
> have to include proper warnings at the end of the build or such...
What I was thinking is just to add a couple make targets for this case:
devices:
mount -v --bind /dev $(LFS)/dev
mount -vt devpts devpts $(LFS)/dev/pts
mount -vt tmpfs shm $(LFS)/dev/shm
mount -vt proc proc $(LFS)/proc
mount -vt sysfs sysfs $(LFS)/sys
teardown:
umount -v $(LFS)/dev/pts
umount -v $(LFS)/dev/shm
umount -v $(LFS)/proc
umount -v $(LFS)/sys
chroot: devices
chroot $(LFS) /tools/bin/env -i \
HOME=/root TERM=$TERM PS1='\u:\w\$ ' \
PATH=/bin:/usr/bin:/sbin:/usr/sbin \
/tools/bin/bash --login
$(MAKE) teardown
At the end of the build, a message could be output:
"Done building packages. To continue preparing the system as
described in Chapter 7, run:
make chroot"
Or whatever (I suck at UI). Those targets would probably need to be
made more robust (and handle gaining root privilege), but you get the
idea.
--
Dan
--
http://linuxfromscratch.org/mailman/listinfo/alfs-discuss
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page