#!/sbin/openrc-run depend() { need localmount need bootmisc } start() { ebegin "Mounting 32-bit chroot directories" mount -o bind /opt/chroot_x86/gentoo32 /chroot/32bit-Gentoo >/dev/null mount -o bind /dev /chroot/32bit-Gentoo/dev >/dev/null mount -o bind /dev/pts /chroot/32bit-Gentoo/dev/pts >/dev/null & mount -o bind /dev/shm /chroot/32bit-Gentoo/dev/shm >/dev/null & mount -o bind /proc /chroot/32bit-Gentoo/proc >/dev/null mount -o bind /sys /chroot/32bit-Gentoo/sys >/dev/null & mount -o bind /tmp /chroot/32bit-Gentoo/tmp >/dev/null & mount -o bind /run/udev /chroot/32bit-Gentoo/run/udev >/dev/null & mount -o bind /usr/portage /chroot/32bit-Gentoo/usr/portage >/dev/null & eend $? "An error occured while attempting to mount 32bit chroot directories" ebegin "Copying 32bit chroot files" cp -pf /etc/resolv.conf /chroot/32bit-Gentoo/etc >/dev/null & cp -pf /etc/hosts /chroot/32bit-Gentoo/etc > /dev/null & cp -Ppf /etc/localtime /chroot/32bit-Gentoo/etc >/dev/null & eend $? "An error occured while attempting to copy 32 bits chroot files." } stop() { ebegin "Unmounting 32-bit chroot directories" umount -f /chroot/32bit-Gentoo/dev/pts >/dev/null umount -f /chroot/32bit-Gentoo/dev/shm >/dev/null umount -f /chroot/32bit-Gentoo/dev >/dev/null & umount -f /chroot/32bit-Gentoo/proc >/dev/null & umount -f /chroot/32bit-Gentoo/sys >/dev/null & umount -f /chroot/32bit-Gentoo/tmp >/dev/null & umount -f /chroot/32bit-Gentoo/run/udev >/dev/null & umount -f /chroot/32bit-Gentoo/usr/portage >/dev/null & umount -f /chroot/32bit-Gentoo >/dev/null & eend $? "An error occured while attempting to unmount 32bit chroot directories" } # mount -o bind /usr/portage chroot/32bit-Gentoo/usr/portage/ >/dev/null & # umount -f chroot/32bit-Gentoo/usr/portage/ >/dev/null &