You also might wanna just use Whisky which does this automatically
This guide works on macOS 13.4+ using Command Line Tools for XCode 15 Beta!
In the recent WWDC, Apple announced and released the "game porting toolkit", which upon further inspection this is just a modified version of CrossOver's fork of wine which is a "compatibility layer" that allows you to run Windows applications on macOS and Linux.
Playing Windows games on MacOS
First, install homebrew which is an amazing macOS package manager, which is weirdly enough what Apple themselves have used for distrobution of this program
brew tap apple/homebrew-apple
This adds apple's offical "repository" for their "forumula" (package), which includes the game-porting-toolkit
Make sure that rosetta2 is installed
/usr/sbin/softwareupdate --install-rosetta --agree-to-license
homebrew to inside Rosetta
arch -x86_64 zsh
cd /usr/local && mkdir homebrew
curl -L github.com/Homebrew/brew/tarball/master | tar xz --strip 1 -C homebrew
arch -x86_64 /usr/local/homebrew/bin/brew tap apple/homebrew-apple
arch -x86_64 /usr/local/homebrew/bin/brew install game-porting-toolkit
Now, you can install the game-porting-toolkit
Warning: This will take a LONG TIME, and will use up a LOT of system resources because it needs to compile a really large project (LLVM)
brew install game-porting-toolkit
Then, go to this url (on apple.com) to download the actual toolkit, place it somewhere memorable.
First, you need to create a "wine prefix" for your game.
To do this,
WINEPREFIX=~/my-game-prefix `brew --prefix game-porting-toolkit`/bin/wine64 winecfg
Where you would replace my-game-prefix
with whatever you want you want it to be.
You should now change (in the window that pops up) the windows version to "windows 10"
Press ok, and then install your game into my-game-prefix
Finally, to install apple's game porting toolkit, use
ditto [REPLACE THIS WITH WHEREVER YOU PUT THE GAME PORTING TOOLKIT]/lib/ `brew --prefix game-porting-toolkit`/lib/
and finally, to run the executable,
[REPLACE THIS WITH WHEREVER YOU PUT THE GAME PORTING TOOLKIT]/gameportingtoolkit ~/my-game-prefix 'C:\\Program Files\\MyGame\\MyGame.exe'
or, for without the debug GUI
[REPLACE THIS WITH WHEREVER YOU PUT THE GAME PORTING TOOLKIT]/gameportingtoolkit-no-hud ~/my-game-prefix 'C:\\Program Files\\MyGame\\MyGame.exe'
TODO
@kotetsuy @Galase had the same issue, root problem is the HOMEBREW_PREFIX used in this guide (/usr/local/homebrew/) is just incorrect. The homebrew prefix really needs to be
/usr/local
Earlier in the build step for
gobject-introspection
you should see a warning, saying it is building from source because the prefix is notusr/local
or similar. Thats the real issue here..To fix this, I had to uninstall the x86_64 version of homebrew completely, and reinstall it with the default prefix (I have no idea when I accidentally introduced this different prefix on my first attempt...or why this guide had the same incorrect prefix). But Immediately after installing, run
brew doctor
and make sure to fix any warnings before going back through the install steps.Good luck!