mirror of
https://github.com/systemd/systemd.git
synced 2025-03-28 02:50:16 +03:00
test-functions: search for the initrd and kernel according to the BLS
Also search for the initrd and kernel according to the boot loader specification.
This commit is contained in:
parent
edbced8a15
commit
b6f0c419e3
@ -42,6 +42,14 @@ function find_qemu_bin() {
|
||||
}
|
||||
|
||||
run_qemu() {
|
||||
if [ -f /etc/machine-id ]; then
|
||||
read MACHINE_ID < /etc/machine-id
|
||||
[ -z "$INITRD" ] && [ -e "/boot/$MACHINE_ID/$KERNEL_VER/initrd" ] \
|
||||
&& INITRD="/boot/$MACHINE_ID/$KERNEL_VER/initrd"
|
||||
[ -z "$KERNEL_BIN" ] && [ -e "/boot/$MACHINE_ID/$KERNEL_VER/linux" ] \
|
||||
&& KERNEL_BIN="/boot/$MACHINE_ID/$KERNEL_VER/linux"
|
||||
fi
|
||||
|
||||
[ "$KERNEL_BIN" ] || KERNEL_BIN=/boot/vmlinuz-$KERNEL_VER
|
||||
[ "$INITRD" ] || INITRD=/boot/initramfs-${KERNEL_VER}.img
|
||||
[ "$QEMU_SMP" ] || QEMU_SMP=1
|
||||
|
Loading…
x
Reference in New Issue
Block a user