Files
riscy-rust/test/start-qemu.sh
Ben Kyd 1cc1cae6b5
Some checks failed
Rust nightly / Check (push) Has been cancelled
CLI, IMA, Linux, UART
2023-07-31 00:12:48 +01:00

15 lines
448 B
Bash

#!/bin/sh
(
BINARIES_DIR="${0%/*}/"
cd ${BINARIES_DIR}
if [ "${1}" = "serial-only" ]; then
EXTRA_ARGS='-nographic'
else
EXTRA_ARGS=''
fi
export PATH="/home/benk/dprog/misc/mini-rv32ima/buildroot/output/host/bin:${PATH}"
exec qemu-system-riscv32 -M virt -bios none -kernel Image -append "rootwait root=/dev/vda ro" -drive file=rootfs.ext2,format=raw,id=hd0 -device virtio-blk-device,drive=hd0 -nographic -cpu rv32,mmu=off ${EXTRA_ARGS}
)