From 52441333d6cd86cd2c055eefa50916dec9c7ab40 Mon Sep 17 00:00:00 2001 From: Ward from fusion-voyager-3 Date: Fri, 2 Aug 2024 01:24:07 +0300 Subject: [PATCH] attempt 3 at fixing UEFI --- .github/release-iso | 2 +- build.sh | 22 ++++++++++++++-------- data/refind/EFI/boot/refind.conf | 6 +++--- info.sh | 2 +- 4 files changed, 19 insertions(+), 13 deletions(-) diff --git a/.github/release-iso b/.github/release-iso index 7ed6ff8..1e8b314 100644 --- a/.github/release-iso +++ b/.github/release-iso @@ -1 +1 @@ -5 +6 diff --git a/build.sh b/build.sh index e70bd2c..e9236bb 100755 --- a/build.sh +++ b/build.sh @@ -50,17 +50,23 @@ mksquashfs \ -Xdict-size 1M \ -Xbcj x86 -# Copy Kernel to live -cp "$ROOTFS_PATH/boot"/vmlinuz-* \ - "$LIVE_BOOT_LIVE_PATH/vmlinuz" && \ -cp "$ROOTFS_PATH/boot"/initrd.img-* \ - "$LIVE_BOOT_LIVE_PATH/initrd" && \ -cp ./data/refind/refind_linux.conf \ - "$LIVE_BOOT_LIVE_PATH/refind_linux.conf" +# Copy Kernel to live (Disabled, Copy Kernels to refind instead) +#cp "$ROOTFS_PATH/boot"/vmlinuz-* \ +# "$LIVE_BOOT_LIVE_PATH/vmlinuz" && \ +#cp "$ROOTFS_PATH/boot"/initrd.img-* \ +# "$LIVE_BOOT_LIVE_PATH/initrd" && \ +#cp ./data/refind/refind_linux.conf \ +# "$LIVE_BOOT_LIVE_PATH/refind_linux.conf" # Generate bootable EFI Image from refind -dd if=/dev/zero of="$LIVE_BOOT_PATH/efiboot.img" bs=1M count=20 +# Copy kernel to refind +cp "$ROOTFS_PATH/boot"/vmlinuz-* \ + "./data/refind/EFI/vmlinuz" && \ +cp "$ROOTFS_PATH/boot"/initrd.img-* \ + "./data/refind/EFI/initrd" + +dd if=/dev/zero of="$LIVE_BOOT_PATH/efiboot.img" bs=1M count=512 mkfs.msdos -F 16 "$LIVE_BOOT_PATH/efiboot.img" for directory in $(find ./data/refind/EFI/ -type d | cut -d'/' -f4-) do diff --git a/data/refind/EFI/boot/refind.conf b/data/refind/EFI/boot/refind.conf index c88b284..fb593d1 100644 --- a/data/refind/EFI/boot/refind.conf +++ b/data/refind/EFI/boot/refind.conf @@ -331,7 +331,7 @@ showtools install,bootorder,shell,memtest,gdisk,apple_recovery,csr_rotate,window # On UEFI PCs, default is internal,external,optical,manual # On Macs, default is internal,hdbios,external,biosexternal,optical,cd,manual # -scanfor manual,firmware +scanfor manual # By default, rEFInd relies on the UEFI firmware to detect BIOS-mode boot # devices. This sometimes doesn't detect all the available devices, though. @@ -649,8 +649,8 @@ csr_values 10,77 menuentry "PikaOS Live Image" { icon EFI/BOOT/REFIND-DARK/ICONS/OS_PIKAOS.PNG - loader /live/vmlinuz - initrd /live/initrd + loader EFI/VMLINUZ + initrd EFI/INITRD options "boot=live quiet splash" submenuentry "Boot live image with logging" { options "boot=live" diff --git a/info.sh b/info.sh index 224a0db..5a0d871 100755 --- a/info.sh +++ b/info.sh @@ -9,6 +9,6 @@ export ISO_DISTNAME="PikaOS" export ISO_ARCH="amd64-v3" export ISO_RELEASE="4.0" export ISO_DESKTOP="GNOME" -export ISO_PATCH="3" +export ISO_PATCH="4" export ISO_IMAGE="$ISO_DISTNAME-$ISO_DESKTOP-$ISO_RELEASE-$ISO_ARCH-$(date '+%y.%m.%d')-$ISO_PATCH" export LIVE_BOOT_VOLUME_NAME="$ISO_DISTNAME-$ISO_DESKTOP-$ISO_RELEASE-$ISO_ARCH-$ISO_PATCH"