diff --git a/src/usbinstall.sh b/src/usbinstall.sh index 1f69d04..d3b2b07 100644 --- a/src/usbinstall.sh +++ b/src/usbinstall.sh @@ -242,7 +242,7 @@ fi # create EFI grub 32 and 64 bit images mkdir -p $MOUNTDIR_EFI/EFI/BOOT/ -grub-mkimage -o $MOUNTDIR_EFI/EFI/BOOT/bootx64.efi -O x86_64-efi -p /efi/boot \ +grub-mkimage -o $MOUNTDIR_EFI/EFI/BOOT/bootx64.efi -O x86_64-efi -p "(,msdos2)/boot/grub" \ part_gpt part_msdos ntfs ntfscomp hfsplus fat ext2 normal chain boot linux echo \ help gfxterm gettext png efi_gop efi_uga search search_label search_fs_uuid || { errorAndExit $"Error: unable to create GRUB x86_64-efi image" &>>$LOGFILE @@ -250,7 +250,7 @@ grub-mkimage -o $MOUNTDIR_EFI/EFI/BOOT/bootx64.efi -O x86_64-efi -p /efi/boot \ # 32bit EFI optional because untested and curently missing in x86_64 arch if [ -d /usr/lib/grub/i386-efi ]; then - grub-mkimage -o $MOUNTDIR_EFI/EFI/BOOT/bootia32.efi -O i386-efi -p /efi/boot \ + grub-mkimage -o $MOUNTDIR_EFI/EFI/BOOT/bootia32.efi -O i386-efi -p "(,msdos2)/boot/grub" \ part_gpt part_msdos ntfs ntfscomp hfsplus fat ext2 normal chain boot linux echo \ help gfxterm gettext png efi_gop efi_uga search search_label search_fs_uuid || { errorAndExit $"Error: unable to create GRUB i386-efi image" &>>$LOGFILE @@ -294,14 +294,14 @@ else ps $CPPID >/dev/null while [ $? -eq 0 ]; do if [ -e $DEST_FILE ]; then - DEST_SIZE=$(stat -c %s $DEST_FILE) - percentuale=$((30 + ( 50 * $DEST_SIZE ) / $ORIG_SIZE )) - set_pbar $percentuale + DEST_SIZE=$(stat -c %s $DEST_FILE) + percentuale=$((30 + ( 50 * $DEST_SIZE ) / $ORIG_SIZE )) + set_pbar $percentuale fi sleep 2 ps $CPPID >/dev/null done - + if [ -e $ISOMOUNTDIR/boot/isolinux/isolinux.cfg ]; then # basic extlinux.conf -> grub.cfg conversion # Legacy for old openmamba iso images with isolinux bootloader @@ -352,13 +352,12 @@ search --no-floppy --label --set=root openmamba_live mkdir boot/grub cp $MOUNTDIR_EFI/EFI/BOOT/grub.cfg boot/grub/grub.cfg - umount $ISOMOUNTDIR - rmdir $ISOMOUNTDIR else cp -a $ISOMOUNTDIR/boot/grub boot/ sed -i "s|root=live:LABEL=[^[:space:]]*|root=live:LABEL=openmamba_live rd.live.overlay=/dev/disk/by-label/openmamba_live:/rwroot|" boot/grub/grub.cfg - cp boot/grub/grub.cfg $MOUNTDIR_EFI/EFI/BOOT/grub.cfg fi + umount $ISOMOUNTDIR + rmdir $ISOMOUNTDIR fi set_pbar 85