title: Tidal on Mac OS X layout: default category: installation

weight: 20

Installing Tidal's dependencies on Mac OS X can be done via homebrew or MacPorts, but choose only one to avoid conflicts with duplicate system libraries.

Unless otherwise specified, the below commands should be typed or pasted into a terminal window.

Dirt

Installing dependencies via Homebrew

Homebrew is a package manager for OS X. It lives side by side with the native libraries and tools that ship with the operating system.

To install homebrew:

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

Initialise homebrew:

brew doctor

Install Dirt, a synth (well, more of a sampler) made to work with Tidal. A homebrew 'recipe' for dirt does exist, but that doesn't come with any sounds to play with, so for now it's probably easiest just download it all from github and compile it as follows.

Install some libraries which the Dirt synth needs to compile:

brew install liblo libsndfile libsamplerate

Install the 'jack audio connection kit' which Dirt also needs:

brew install jack

Note: If Homebrew's installation of Jack fails with a make error, you can use the JackOSX Installer instead. This will, however, add an additional step when installing Dirt (see below)

Alternative: Installing dependencies via Mac Ports

MacPorts is another package manager for OS X. If you already installed dependencies via homebrew, skip ahead to build Dirt.
Otherwise if you happen to already use MacPorts, here's a list of steps in order to get all dependencies:

sudo port install liblo libsndfile libsamplerate

Download and install jack2 Jack Download Page. Jack 2 has better OS X integration Jack Comparison.

Building Dirt from source

Get the source code for the Dirt synth:

cd ~
git clone --recursive https://github.com/tidalcycles/Dirt.git

Compile dirt:

cd ~/Dirt
make clean; make

If Dirt fails to compile after using the JackOSX installer as above, you may need to add flags to the Makefile to specify the appropriate paths:

CFLAGS += -g -I/usr/local/include -Wall -O3 -std=gnu99 -DCHANNELS=2
LDFLAGS += -lm -L/usr/local/lib -llo -lsndfile -lsamplerate -ljack

As MacPorts installs all libs on /opt/local/ edit the Makefile to point the right direction of libsndfile and libsamplerate

CFLAGS += -g -I/opt/local/include -Wall -O3 -std=gnu99
LDFLAGS += -lm -L/opt/local/lib  -llo -lsndfile -lsamplerate

Haskell

get the binary installer for GHC.
Or you might get it from homebrew:

brew install ghc

Or, if using MacPorts:

sudo port install ghc

Install Tidal itself:

cabal update
cabal install cabal-install
cabal install tidal

On OS X with GHC 7.10 it is necessary to reinstall PortMidi again with frameworks correctly linked:

cabal install portmidi --ghc-options="-optl-Wl,-framework,CoreMIDI,-framework,CoreAudio" --reinstall --jobs=1 --force-reinstalls

Now you have to start dirt, the synthesizer/sampler, before getting a code editor going. So back in a terminal window, start jack:

jackd -d coreaudio &

Or, if you downloaded Jack 2, then start the JackPilot at: /Applications/Jack/JackPilot.app Click start button.

Then start dirt:

cd ~/Dirt
./dirt &

You will have to start dirt every time you want to run Tidal, otherwise there will be no sound.

Now you need to install and configure an editor, following the instructions below. For beginners, the Atom editor is recommended.