Installing and building the ledger on Mac

Supported platforms

  • MacOS Darwin 10.13x and higher (64bit)

Initial setup

Get homebrew:

/usr/bin/ruby -e "$(curl -fsSL"

Install dependencies:

brew install cmake openssl git python

Or with MacPorts:

port install cmake openssl git python

If you use homebrew, edit your ~/.bash_profile :

export OPENSSL_ROOT_DIR="/usr/local/Cellar/openssl/`ls /usr/local/Cellar/openssl/ | sort | tail -1`"

Add the git alias:

git config --global alias.pullall '!f(){ git pull "[email protected]" && git submodule sync --recursive && git submodule update --init --recursive; }; f'

Download the ledger code

If you need them, here are the Git SSH key generation instructions.

Clone the repository:

cd [working_directory]
git clone
git checkout release/v0.9.x

Update and initialise submodules from the repository root directory:

cd ledger
git pull
git submodule update --init --recursive

Make sure you have all the submodules:

git submodule status

If any submodules are missing, please check your installation.

Build the ledger

From the ledger directory, follow the steps to build the library:

mkdir build
cd build
cmake ..
make -j constellation

You may have memory issues on make, so limit the number of cores (we chose 4):

make -j 4 constellation

If you want, you can build all the libraries:

make -j 4

For the etch simulator, build the etch library:

make etch

Possible gotchas

To avoid issues with OpenSSL, run the following:

cmake -DOPENSSL_ROOT_DIR=/usr/local/ssl -DOPENSSL_LIBRARIES=/usr/local/ssl/lib