OS X Build Instructions

Ashot Nazaryan edited this page Apr 22, 2016 · 7 revisions

Installing Homebrew & Dependencies

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
brew install git
brew update
brew tap tomahawk-player/tomahawkqt5
brew install qtkeychain
brew install tomahawk-player/tomahawkqt5/qca --with-qt5 --without-qt
brew install --HEAD lucenepp --c++11
brew install jreen
brew install --HEAD websocketpp
brew install vlc
brew install --HEAD tomahawk-player/tomahawkqt5/quazip
brew install --HEAD tomahawk-player/tomahawkqt5/liblastfm
brew install --HEAD extracmakemodules
brew install `brew deps tomahawk`

Compiling Tomahawk

git clone git://github.com/tomahawk-player/tomahawk.git
mkdir tomahawk/build && cd tomahawk/build
export PATH=/usr/local/opt/qt5/bin:$PATH
cmake -DBUILD_WITH_QT4=OFF -DPC_ECHONEST_VERSION=2.3.0 -DBUILD_TOOLS=OFF ..
make
open tomahawk.app

Troubleshooting

Note, you must have XCode's Command Line Tools installed to compile Tomahawk.

Compiling on Mavericks

Disable Breakpad by running cmake again: cmake -DWITH_BREAKPAD=OFF ..

VLC won't build on Yosemite

you will need a copy of libVLC that was build on an early version of OS X and put that in /usr/local/Cellar brew link vlc

Some have reported success with building VLC on Yosemite by following these directions.

Updating Qt

After updating to a newer Qt version, you need to run the following commands to compile and link the dependencies against the new Qt:

 cd /usr/local
 brew cleanup
 packages_using_qt=`brew uses --installed qt`
 echo $packages_using_qt | xargs brew remove
 echo $packages_using_qt | xargs brew install
 unset packages_using_qt
 cd tomahawk
 rm -rf build

Then start again from creating the build directory.

CMake Failed to Execute

If you get 'Failed to execute: cmake' try again with a standard environment. For example the below.

brew install --env=std tomahawk-player/tomahawk/libechonest

Updating Homebrew Tap

Sometimes a new package gets added to Tomahawk's tap. To update the tap, untap then tap again.

 brew untap tomahawk-player/tomahawkqt5
 brew tap tomahawk-player/tomahawkqt5

Runtime Issues

Application Database and Preferences

In the case of a crash when nothing else seems to clear out a problem and the Tomahawk devs say it's ok to remove them, these are the paths to Tomahawk's database, cache and preferences.

Database and Cache

 ~/Library/Application Support/Tomahawk

Preferences

 ~/Library/Preferences/org.tomahawk-player.*