From 689fe7ddfff49566d18eb64a1944b521f63e582d Mon Sep 17 00:00:00 2001 From: serenityosrocks Date: Thu, 6 Jan 2022 17:21:41 -0800 Subject: [PATCH] Meta: Make "Meta/serenity.sh run aarch64" work on macOS --- Meta/run.sh | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/Meta/run.sh b/Meta/run.sh index 0479c3ccaf..5a0ae0bfec 100755 --- a/Meta/run.sh +++ b/Meta/run.sh @@ -30,9 +30,13 @@ fi # To support virtualization acceleration on mac # we need to use 64-bit qemu -if [ "$(uname)" = "Darwin" ] && [ "$(uname -m)" = "x86_64" ]; then +if [ "$(uname)" = "Darwin" ]; then - [ -z "$SERENITY_QEMU_BIN" ] && SERENITY_QEMU_BIN="qemu-system-x86_64" + if [ "$SERENITY_ARCH" != "aarch64" ]; then + [ -z "$SERENITY_QEMU_BIN" ] && SERENITY_QEMU_BIN="qemu-system-x86_64" + else + [ -z "$SERENITY_QEMU_BIN" ] && SERENITY_QEMU_BIN="qemu-system-aarch64" + fi if $SERENITY_QEMU_BIN --accel help | grep -q hvf; then SERENITY_VIRT_TECH_ARG="--accel hvf" @@ -212,7 +216,7 @@ fi if [ -z "$SERENITY_MACHINE" ]; then if [ "$SERENITY_ARCH" = "aarch64" ]; then - SERENITY_MACHINE="-M raspi3 -serial stdio" + SERENITY_MACHINE="-M raspi3b -serial stdio" else SERENITY_MACHINE=" -m $SERENITY_RAM_SIZE