Git-Url: http://git.frugalware.org/gitweb/gitweb.cgi?p=fw-initramfs.git;a=commitdiff;h=af8c63956fa8a1a79ba2fff5a413284578963fd5
commit af8c63956fa8a1a79ba2fff5a413284578963fd5 Author: bouleetbil <bouleet...@frogdev.info> Date: Sat Nov 21 18:26:41 2009 +0100 create_usblive.sh *some fix for install mbr diff --git a/create_usblive.sh b/create_usblive.sh index 3f744c4..4a233f6 100755 --- a/create_usblive.sh +++ b/create_usblive.sh @@ -83,9 +83,7 @@ pacman-g2 -Sy core base -r $MNTTMP --noconfirm ##################################################################### #configure the chroot ##################################################################### -mount -t proc none $MNTTMP/proc -mount -t sysfs none $MNTTMP/sys -mount -o bind /dev $MNTTMP/dev +mkdir -p $MNTTMP/etc cp -f /etc/fstab $MNTTMP/etc/ cp -f /etc/mtab $MNTTMP/etc/ cp -f /etc/resolv.conf $MNTTMP/etc/ @@ -103,29 +101,15 @@ cp -f /etc/sysconfig/keymap $MNTTMP/etc/sysconfig/keymap ##################################################################### cd $HOMESOURCE ./create_initramfs.sh -cp ${DIRTEMP}work/initramfs.igz $MNTTMP/boot/ +mkdir -p $MNTTMP/boot/ +cp ${DIRTEMP}work/initramfs.igz $MNTTMP/boot/initramfs.igz ##################################################################### #copy fstab for usbkey ##################################################################### -cp -f fstab.usbkey $MNTTMP/etc/fstab +cp -f $HOMESOURCE/fstab.usbkey $MNTTMP/etc/fstab DDUID=` blkid | grep ${USBDEVICE} | cut -d \" -f 2` -echo "${DDUID}    /    ext3   defaults    1 1 " >> $MNTTMP/etc/fstab - -##################################################################### -#syslinux install -##################################################################### - -Build_Syslinux -mkdir -p $MNTTMP/boot -$HOMESOURCE/static/syslinux/sbin/extlinux -i $MNTTMP/boot -cp $HOMESOURCE/extlinux.conf $MNTTMP/boot/extlinux.conf -echo "append /boot/vmlinuz ro root=UUID=${DDUID} quiet CONSOLE=/dev/tty1 bootusb" >> $MNTTMP/extlinux.conf -#install the mbr -cat $HOMESOURCE/static/syslinux/usr/share/syslinux/mbr.bin > ${USBDEVICE:0:8} -umount $MNTTMP/proc -umount $MNTTMP/sys -umount $MNTTMP/dev +echo "${DDUID}    /    ext2   defaults    1 1 " >> $MNTTMP/etc/fstab ##################################################################### #change password root @@ -135,7 +119,25 @@ chroot $MNTTMP passwd ##################################################################### #this file is detected by initramfs for determine / ##################################################################### -date > $MNTTMP/FrugalMove +date > $MNTTMP/FrugalMove + +##################################################################### +#syslinux install +##################################################################### + +Build_Syslinux +mkdir -p $MNTTMP/boot/extlinux +cp $HOMESOURCE/extlinux.conf $MNTTMP/boot/extlinux.conf +echo "append initrd=/boot/initramfs.igz ro root=UUID=${DDUID} quiet CONSOLE=/dev/tty1 bootusb" >> $MNTTMP/boot/extlinux.conf + +#install extlinux +$HOMESOURCE/static/syslinux/sbin/extlinux -i $MNTTMP/boot + +#umount filesystem +umount $MNTTMP + +#install mbr +cat $HOMESOURCE/static/syslinux/usr/share/syslinux/mbr.bin > ${USBDEVICE:0:8} good_msg "Usb key Frugalware is created !" good_msg "For add a new user :"
_______________________________________________ Frugalware-git mailing list Frugalware-git@frugalware.org http://frugalware.org/mailman/listinfo/frugalware-git