From 93a4065deadbd6678de13683b1b06a2448281a5a Mon Sep 17 00:00:00 2001 From: Josh Holtrop Date: Mon, 4 Sep 2023 14:07:05 -0400 Subject: [PATCH] Add path to OVMF.fd for Arch --- Rsconscript | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Rsconscript b/Rsconscript index 872c7e0..ebd44b2 100644 --- a/Rsconscript +++ b/Rsconscript @@ -186,7 +186,11 @@ task "run", desc: "Run HOS in QEMU" do Dir.mktmpdir do |tmpdir| img = hello_env.expand("^/HOS.img") FileUtils.cp(img, tmpdir) - sh %W[qemu-system-x86_64 -cpu max -bios OVMF.fd -drive file=#{tmpdir}/HOS.img,format=raw -device qemu-xhci -device usb-tablet] + ovmf = "OVMF.fd" + if File.exist?("/usr/share/edk2/x64/OVMF.fd") + ovmf = "/usr/share/edk2/x64/OVMF.fd" + end + sh %W[qemu-system-x86_64 -cpu max -bios #{ovmf} -drive file=#{tmpdir}/HOS.img,format=raw -device qemu-xhci -device usb-tablet] end end