From 31b406994550a9401000384d8ad06457c4a499df Mon Sep 17 00:00:00 2001 From: Ralph Ronnquist Date: Wed, 30 Oct 2024 08:23:33 +1100 Subject: [PATCH] Allow for various namings of the linux kernel package --- build-installer.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/build-installer.sh b/build-installer.sh index 0c5545b..68e117d 100755 --- a/build-installer.sh +++ b/build-installer.sh @@ -230,8 +230,10 @@ sed 's/iso9960\b/squashfs/' -i $INITRD/var/lib/dpkg/info/cdrom-detect.postinst # Pack up $INITRD into a top-level initrd.gz, and copy out vmlinuz find $INITRD -not -name udebs -printf '%P\n' | \ fakeroot cpio -o -H newc -D $INITRD | gzip > $TARGET_ARCH/initrd.gz -VMLINUZ=$INITRD/boot/vmlinuz-$KERNELVERSION +VMLINUZ="$INITRD/boot/vmlinuz-$KERNELVERSION" +[ -r "$VMLINUZ" ] || VMLINUZ="$INITRD/boot/vmlinuz" +[ -r "$VMLINUZ" ] || VMLINUZ="$INITRD/boot/vmlinux-$KERNELVERSION" +[ -r "$VMLINUZ" ] || VMLINUZ="$INITRD/boot/vmlinux" +cp $VMLINUZ $TARGET_ARCH/ && ln -sTf "${VMLINUZ#***/}" $TARGET_ARCH/kernel #-- Note that this renames it to vmlinuz regarless of its real name #-- Eg the riscv64 kernel is actually not compressed -cp $VMLINUZ $TARGET_ARCH/vmlinuz - -- 2.39.2