Install qemu with brew under x86 in M1 Mac OS

About Qemu-system-ppc, a PPC Mac emulator for Windows, macOS and Linux that can run Mac OS 9.0 up to Mac OS X 10.5

Moderators: Cat_7, Ronald P. Regensburg

Post Reply
violetrose20
Space Cadet
Posts: 1
Joined: Sun Feb 21, 2021 9:44 pm

Install qemu with brew under x86 in M1 Mac OS

Post by violetrose20 »

I found it someone can run emulation on M1 Big Sur os.

https://forums.macrumors.com/threads/su ... .2280185/

I bought Mac mini 1M (Big Sur) last 3 weeks ago.
I tried install arch -x86_64 QEMU with brew but unable install it.

user@Mac-mini ~ % arch -x86_64 brew install qemu
Updating Homebrew...
Error: Cannot install under Rosetta 2 in ARM default prefix (/opt/homebrew)!
To rerun under ARM use:
arch -arm64 brew install ...
To install under x86_64, install Homebrew into /usr/local.
user@Mac-mini ~ %

How to install under x86_64? Where is /usr/local? I tried cd /usr/local but not found it.
User avatar
Cat_7
Expert User
Posts: 5478
Joined: Fri Feb 13, 2004 8:59 am
Location: Sittard, The Netherlands

Re: Install qemu with brew under x86 in M1 Mac OS

Post by Cat_7 »

I guess you first need to install x86_64 brew to have it create the /usr/local folder etc:
arch -x86_64 /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homeb ... install.sh)"

Then run:
arch -x86_64 brew install qemu

But I believe current Qemu can also be compiled directly under aarch64. So if you have all dependencies installed with brew, you can clone the Qemu repository and build qemu-system-ppc yourself.

Best,
Cat_7
violetrose20
Space Cadet
Posts: 1
Joined: Sun Feb 21, 2021 9:44 pm

Re: Install qemu with brew under x86 in M1 Mac OS

Post by violetrose20 »

I erased my mac mini then reinstalled Big Sur after stuck loading on privacy & data. I installed arch -x86_64 brew install qemu on terminal, It's worked and running working too! Thank you.
Last edited by violetrose20 on Thu Feb 25, 2021 10:07 pm, edited 2 times in total.
tobysun
Space Cadet
Posts: 1
Joined: Wed Sep 15, 2021 2:41 am

Re: Install qemu with brew under x86 in M1 Mac OS

Post by tobysun »

violetrose20 wrote: Thu Feb 25, 2021 10:05 pm I erased my mac mini then reinstalled Big Sur after stuck loading on privacy & data. I installed arch -x86_64 brew install qemu on terminal, It's worked and running working too! Thank you.
Hi, this bother me too, I install the qemu by x86-brew and I can run the qemu-system-x86_64 with no accel, when I run with "--accel hvf", it broken . Do you have the same problem? thanks.
Post Reply