2023-07-19 02:08:59 +00:00
|
|
|
#! /bin/sh
|
2023-07-19 07:38:47 +00:00
|
|
|
set -eux
|
2023-07-19 02:08:59 +00:00
|
|
|
|
|
|
|
|
# Cargo passes the path to the built executable as the first argument.
|
|
|
|
|
KERNEL=$1
|
|
|
|
|
|
|
|
|
|
# Copy the needed files into an ISO image.
|
2023-07-20 11:40:13 +00:00
|
|
|
mkdir -p target/iso_root/boot
|
2023-07-19 07:38:47 +00:00
|
|
|
cp $KERNEL target/iso_root/boot/jinux
|
2023-07-19 02:08:59 +00:00
|
|
|
mkdir -p target/iso_root/boot/grub
|
|
|
|
|
cp build/grub/conf/grub.cfg target/iso_root/boot/grub
|
|
|
|
|
|
|
|
|
|
# Copy ramdisk
|
2023-07-19 07:38:47 +00:00
|
|
|
cp regression/build/ramdisk.cpio.gz target/iso_root/boot
|
2023-07-19 02:08:59 +00:00
|
|
|
|
|
|
|
|
# Make boot device .iso image
|
|
|
|
|
grub-mkrescue -o $KERNEL.iso target/iso_root
|