From 2ac8096ba06c44be152b8112b45f9e263458757c Mon Sep 17 00:00:00 2001 From: David P Date: Sun, 29 May 2022 22:05:27 -0400 Subject: search edk2-shell in packages.both, search refind files directly in efiboot/ Signed-off-by: David P --- parabolaiso/mkparabolaiso | 31 ++++++++++++------------------- 1 file changed, 12 insertions(+), 19 deletions(-) (limited to 'parabolaiso') diff --git a/parabolaiso/mkparabolaiso b/parabolaiso/mkparabolaiso index 169fea9..6acc53e 100755 --- a/parabolaiso/mkparabolaiso +++ b/parabolaiso/mkparabolaiso @@ -705,12 +705,12 @@ _make_bootmode_uefi-x64.refind.esp() { _msg_info "Setting up rEFInd for UEFI booting..." # Calculate the required FAT image size in bytes - efiboot_imgsize="$(du -bc \ - "${pacstrap_dir}/usr/share/refind/refind_x64.efi" \ - "${pacstrap_dir}/usr/share/edk2-shell/x64/Shell_Full.efi" \ - "${profile}/efiboot/" \ - "${pacstrap_dir}/boot/vmlinuz-"* \ - "${pacstrap_dir}/boot/initramfs-"*".img" \ + efiboot_files+=("${pacstrap_dir}/usr/share/refind/refind_x64.efi" \ + "${pacstrap_dir}/usr/share/edk2-shell/x64/Shell_Full.efi" \ + "${profile}/efiboot/" \ + "${pacstrap_dir}/boot/vmlinuz-"* \ + "${pacstrap_dir}/boot/initramfs-"*".img") + efiboot_imgsize="$(du -bc "${efiboot_files[@]}" \ 2>/dev/null | awk 'END { print $1 }')" # Create a FAT image for the EFI system partition _make_efibootimg "$efiboot_imgsize" @@ -721,8 +721,8 @@ _make_bootmode_uefi-x64.refind.esp() { # Copy rEFInd configuration files mmd -i "${work_dir}/efiboot.img" ::/EFI/BOOT/entries - mcopy -i "${work_dir}/efiboot.img" "${profile}/efiboot/EFI/BOOT/refind.conf" ::/EFI/BOOT/ - for _conf in "${profile}/efiboot/EFI/BOOT/entries/"*".conf"; do + mcopy -i "${work_dir}/efiboot.img" "${profile}/efiboot/refind.conf" ::/EFI/BOOT/ + for _conf in "${profile}/efiboot/entries/"*".conf"; do sed "s|%PARABOLAISO_LABEL%|${iso_label}|g; s|%INSTALL_DIR%|${install_dir}|g; s|%ARCH%|${arch}|g" \ @@ -759,8 +759,8 @@ _make_bootmode_uefi-x64.refind.eltorito() { # Copy rEFInd configuration files install -d -m 0755 -- "${isofs_dir}/EFI/BOOT/entries" - install -m 0644 -- "${profile}/efiboot/EFI/BOOT/refind.conf" "${isofs_dir}/EFI/BOOT/" - for _conf in "${profile}/efiboot/EFI/BOOT/entries/"*".conf"; do + install -m 0644 -- "${profile}/efiboot/refind.conf" "${isofs_dir}/EFI/BOOT/" + for _conf in "${profile}/efiboot/entries/"*".conf"; do sed "s|%PARABOLAISO_LABEL%|${iso_label}|g; s|%INSTALL_DIR%|${install_dir}|g; s|%ARCH%|${arch}|g" \ @@ -839,15 +839,8 @@ _validate_common_requirements_bootmode_uefi-x64() { fi # Check for optional packages - if [[ "${arch}" == "dual" ]]; then - # shellcheck disable=SC2154 - if [[ ! " ${pkg_list_x86_64[*]} " =~ ' edk2-shell ' ]]; then - _msg_info "'edk2-shell' is not in the x86_64 package list. The ISO will not contain a bootable UEFI shell." - fi - elif [[ "${arch}" == "x86_64" ]]; then - if [[ ! " ${pkg_list[*]} " =~ ' edk2-shell ' ]]; then - _msg_info "'edk2-shell' is not in the package list. The ISO will not contain a bootable UEFI shell." - fi + if [[ ! " ${pkg_list[*]} " =~ ' edk2-shell ' ]]; then + _msg_info "'edk2-shell' is not in the package list. The ISO will not contain a bootable UEFI shell." fi } -- cgit v1.2.2