Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/pret/pokeemerald/llms.txt

Use this file to discover all available pages before exploring further.

Prerequisites

Choose the tab for your platform and follow the steps to install the required packages.
On Windows, WSL1 is the recommended option — it is the fastest terminal for building pokeemerald. msys2 is approximately 2x slower than WSL1, and Cygwin is 5–6x slower.
WSL1 is the preferred terminal to build pokeemerald on Windows 10 and 11.
1

Install WSL1

Open Windows PowerShell as Administrator and run:
wsl --install -d Ubuntu --enable-wsl1
Once the process finishes, restart your machine.
2

Configure Ubuntu to use WSL1

After restarting, open Windows PowerShell as Administrator again and run:
wsl --set-version Ubuntu 1
3

Set up Ubuntu

Open Ubuntu (e.g. via Search). WSL will complete its first-time setup and prompt you to create a username and password.Then update the system:
sudo apt update && sudo apt upgrade
4

Install required packages

sudo apt install build-essential binutils-arm-none-eabi git libpng-dev
If the above command does not work, try replacing apt with apt-get.
All Windows instructions assume the default drive is C:\. If your drive letter differs, replace C with the correct letter throughout these instructions.

Cloning the repository

Once your environment is set up, clone the source and build the custom GBA C compiler (agbcc).
1

Clone pokeemerald

git clone https://github.com/pret/pokeemerald
2

Clone and build agbcc

agbcc is the custom GBA C compiler required for a byte-identical build. Clone it into the same directory as pokeemerald, then build and install it:
git clone https://github.com/pret/agbcc
cd agbcc
./build.sh
./install.sh ../pokeemerald
After installation, return to the parent directory:
cd ..
3

Enter the pokeemerald directory

cd pokeemerald
You are now ready to build.