How to Install Xonotic on an Apple Silicon Mac
Introduction
For beginners with no command-line experience
Xonotic is a free, fast-paced first-person shooter. It doesn’t yet come in a ready-made download for Apple Silicon Macs (M1, M2, M3), but you can still get it running with just a few setup steps.
This guide will walk you through everything, even if you've never used Terminal before.
1. Install Xcode Command Line Tools
These tools help your Mac build and run programs. They come from Apple and are safe to install.
How to do it:
- Click on Launchpad (the rocket icon in your Dock) or press Command + Space.
- Type Terminal into the search bar and click it to open.
- In Terminal, paste this command and press Return:
A small window will pop up. Click Install and wait a few minutes for it to finish.
You'll always know Terminal is finished with a process when it returns a line like:
YourLoginName@Your-Computer-Name ~ %
2. Install Homebrew
Homebrew is a package manager that makes it easy to install the other tools we’ll need.
In Terminal, paste this and press Return:
You may be prompted to enter your computer password. Type it in and press Return. You will not see it appear on screen.
Follow the instructions on screen as the software installs.
Important: You will likely see a warning at the end stating that Homebrew is not in your PATH. If you do, scroll to the bottom where it says "Next steps" and follow the instructions by copying and pasting the three lines into Terminal one by one, hitting Return after each line.
3. Install Xonotic's Required Libraries
Now we’ll use Homebrew to install a few things Xonotic needs to build and run.
In Terminal, paste each line one at a time and press Return after each, allowing for each one to complete:
Homebrew will inform you with a warning if gmp is already installed. There is no need to reinstall it.
Now we’ll help your system find these libraries later by setting two environment variables.
In Terminal, paste this and press Return:
This opens a simple text editor. Use your down arrow key to go below the existing text at the top and paste these two lines:
Then do the following:
- Press Control + X to exit
- Press Y to confirm saving
- Press Return to finish
Now paste this into Terminal and press Return:
4. Download and Install Xonotic
We’ll download the game files and move them to your Applications folder.
In Terminal, paste each of these one at a time and press Return after each, allowing for each one to complete::
This may take a while as it downloads game assets. When it's done, move the folder into your applications folder by pasting the following and pressing Return:
5. Fix a Small Error
The game’s build system expects a Linux option that doesn’t work on Macs, but we can fix it easily.
Do this:
- Open Finder.
- Go to Applications > xonotic > gmqcc.
- Double-click Makefile (or open with TextEdit).
- Search for
--gc-sections
and replace it with-dead_strip
. - Save the file and close it.
Now go back to Terminal and run:
6. Create a Clickable Xonotic App (like a regular Mac app)
- Open Automator (press Command + Space, type "Automator").
- Choose New Document > Application.
- Search for and double-click Run Shell Script.
- Paste this code into the script box (you may need to paste over any existing text, like "cat"):
- Go to File > Save, name it “Xonotic”, and save it in your Applications folder.
Optional: Add a custom icon
- Use the Xonotic icon below (right-click on it and download it) or find one online and open it in Preview.
- Press Command + A then Command + C.
- Right-click your new Xonotic app in your applications folder and choose Get Info.
- Click the small icon at the top-left and press Command + V to paste.

7. You're Ready to Play!
Double-click your new Xonotic app in Applications or add it to your Dock.
To quit the game, press Command + Q or use the in-game menu.