mirror of
https://github.com/linuxkit/linuxkit.git
synced 2025-09-14 22:31:27 +00:00
Change to use kernel not bzImage everywhere
Previously we hardcoded `bzImage` which is not used for all use cases or architectures. fix #1630 Signed-off-by: Justin Cormack <justin.cormack@docker.com>
This commit is contained in:
@@ -5,7 +5,7 @@ set -e
|
||||
mkdir -p /tmp/efi
|
||||
cd /tmp/efi
|
||||
|
||||
# input is a tarball of vmlinuz64 and initrd.img on stdin
|
||||
# input is a tarball of kernel and initrd.img on stdin
|
||||
# output is an iso on stdout
|
||||
|
||||
# extract. BSD tar auto recognises compression, unlike GNU tar
|
||||
@@ -13,11 +13,11 @@ cd /tmp/efi
|
||||
[ -t 0 ] || bsdtar xzf -
|
||||
|
||||
INITRD="$(find . -name '*.img')"
|
||||
KERNEL="$(find . -name vmlinuz64 -or -name bzImage)"
|
||||
KERNEL="$(find . -name kernel -or -name bzImage)"
|
||||
CMDLINE="$*"
|
||||
|
||||
[ "$KERNEL" = "vmlinuz64" ] || mv "$KERNEL" vmlinuz64
|
||||
[ "$INITRD" = "initrd.img" ] || mv "$INITRD" initrd.img
|
||||
[ "$KERNEL" = "./kernel" ] || mv "$KERNEL" kernel
|
||||
[ "$INITRD" = "./initrd.img" ] || mv "$INITRD" initrd.img
|
||||
|
||||
# clean up subdirectories
|
||||
find . -mindepth 1 -maxdepth 1 -type d | xargs rm -rf
|
||||
@@ -30,8 +30,8 @@ echo "${CMDLINE} rootdelay=300 noautodetect" > cmdline.txt
|
||||
objcopy \
|
||||
--add-section .osrel=/etc/os-release --change-section-vma .osrel=0x20000 \
|
||||
--add-section .cmdline=./cmdline.txt --change-section-vma .cmdline=0x30000 \
|
||||
--add-section .linux=./vmlinuz64 --change-section-vma .linux=0x40000 \
|
||||
--add-section .initrd=initrd.img --change-section-vma .initrd=0x3000000 \
|
||||
--add-section .linux=./kernel --change-section-vma .linux=0x40000 \
|
||||
--add-section .initrd=./initrd.img --change-section-vma .initrd=0x3000000 \
|
||||
./linuxx64.efi.stub \
|
||||
linuxkit.efi
|
||||
|
||||
|
Reference in New Issue
Block a user