qemu: allow the user to specify the kernel flavor (#1256)

This commit is contained in:
Luca Weiss 2018-02-25 20:20:22 +01:00 committed by Oliver Smith
parent 948b5af09b
commit 6b9e7ecf75
2 changed files with 6 additions and 1 deletions

View file

@ -114,7 +114,10 @@ def command_qemu(args, arch, device, img_path, spice_enabled):
suffix = "rootfs_" + device
rootfs = args.work + "/chroot_" + suffix
flavor = pmb.chroot.other.kernel_flavor_autodetect(args, suffix)
if args.flavor:
flavor = args.flavor
else:
flavor = pmb.chroot.other.kernel_flavor_autodetect(args, suffix)
command = [qemu_bin]
command += ["-kernel", rootfs + "/boot/vmlinuz-" + flavor]
command += ["-initrd", rootfs + "/boot/initramfs-" + flavor]