Skip to content

Instantly share code, notes, and snippets.

@zentis
Created May 10, 2016 23:38
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save zentis/b3c55f67f79e2931a2ec0e257b15ef90 to your computer and use it in GitHub Desktop.
Save zentis/b3c55f67f79e2931a2ec0e257b15ef90 to your computer and use it in GitHub Desktop.
Compile Luma 3DS on OS X
Quick Instructions for Compiling under OS X
1. Install gcc from Homebrew and set the env variables + aliases:
export CC=/usr/local/bin/gcc-5
export CXX=/usr/local/bin/g++-5
export CPP=/usr/local/bin/cpp-5
export LD=/usr/local/bin/gcc-5
alias c++=/usr/local/bin/c++-5
alias g++=/usr/local/bin/g++-5
alias gcc=/usr/local/bin/gcc-5
alias cpp=/usr/local/bin/cpp-5
alias ld=/usr/local/bin/gcc-5
alias cc=/usr/local/bin/gcc-5
2. Download the perl script for devkitPro at http://sourceforge.net/projects/devkitpro/files/Automated%20Installer/devkitARMupdate.pl/download
cd /path/to/the/script
chmod +x devkitARMupdate.pl
sudo ./devkitARMupdate.pl /opt/devkitPro
echo "export DEVKITPRO=/opt/devkitPro" >> ~/.bashrc
echo "export DEVKITARM=\$DEVKITPRO/devkitARM" >> ~/.bashrc
echo "export PATH=\$PATH:\$DEVKITARM/bin" >> ~/.bashrc
source ~/.bashrc
4. Replace libctru with Smealum's version
You can get his libctru at https://github.com/smealum/ctrulib.git
Compile with make and then replace libctru from /opt/devkitPro with smealum's version
5. Install gcc-arm-embedded with brew install Caskroom/cask/gcc-arm-embedded
6. Armips and bincc
Armips:
First install cmake if you don't have it. Then:
git clone --recursive https://github.com/Kingcom/armips.git
cd armips
mkdir build; cd build; cmake ..; make
(Remember to build with gcc from homebrew not clang)
bin2c:
Get bin2c from here https://sourceforge.net/projects/bin2c/files/1.1/bin2c-1.1.zip/download
gcc bin2.c -o bin2c
7. Get Luma 3ds repository (clone --recursive) and run make
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment