Created Compiling from Source (markdown)

davidsansome 2013-12-01 00:20:12 -08:00
parent fe2455ad38
commit 96be2b7868
1 changed files with 97 additions and 0 deletions

97
Compiling-from-Source.md Normal file

@ -0,0 +1,97 @@
### Introduction
You probably don't need to compile Clementine yourself. [We already provide downloads](http://www.clementine-player.org/downloads) for Ubuntu, Fedora, Windows and Mac OS X. If you don't want to use one of the above packages, or you want to compile the latest version of Clementine from git, then read on.
The instructions below are for Linux. Compiling for Windows or Mac OS X is a little more complicated.
Note that **Slackware** users can use [the build script](http://lassi.hakkerit.fi/slack/clementine/) maintained by Lassi Kojo.
### Prerequisites
You need CMake and the development packages for these libraries:
* boost
* gettext
* libgstreamer
* libgstreamer-plugins-base
* liblastfm
* Qt 4
* taglib
* libfftw3 or libchromaprint
* GLEW
* libqjson
* libsqlite3
* libgpod (optional, for iPod support)
* libplist (optional, for iPod support)
* libusbmuxd (optional, for iPod support)
* libmtp (optional, for MTP support)
* libgio (optional, for various device support)
* libcdio (optional, for CD support)
* libprotobuf and protobuf-compiler (optional, for Spotify support)
* libspotify (optional, for Spotify support)
* libqca (optional, for Spotify support)
* libsparsehash (optional, for Google Drive support)
On Ubuntu you can install everything you need with:
sudo apt-get install liblastfm-dev libtag1-dev gettext libboost-dev \
libboost-serialization-dev libqt4-dev qt4-dev-tools libqt4-opengl-dev \
cmake libgstreamer0.10-dev libgstreamer-plugins-base0.10-dev \
libglew1.5-dev libqjson-dev libgpod-dev libplist-dev \
libusbmuxd-dev libmtp-dev libcdio-dev \
protobuf-compiler libprotobuf-dev libqca2-dev libqca2-plugin-ossl \
libfftw3-dev libsparsehash-dev libsqlite3-dev
On Fedora:
su -c "yum install gcc-c++ liblastfm-devel taglib-devel gettext boost-devel \
qt-devel cmake gstreamer-devel gstreamer-plugins-base-devel glew-devel \
libgpod-devel qjson-devel libplist-devel \
usbmuxd-devel libmtp-devel protobuf-devel protobuf-compiler qca2-devel \
llibcdio-devel qca-ossl fftw-devel sparsehash-devel sqlite-devel"
On openSUSE:
sudo zypper install cmake libqt4-devel gcc gcc-c++ boost-devel liblastfm-devel \
gettext-tools glew-devel taglib-devel gstreamer-0_10-devel \
gstreamer-0_10-plugins-base-devel libmtp-devel ligpod-devel \
libqjson-devel libplist-devel \
libusbmuxd-devel libcdio-devel fftw3-devel protobuf-devel \
libprotobuf-lite6 sqlite-devel
On Mandriva:
su -c "urpmi gcc-c++ gcc libqt4-devel cmake libtaglib-devel boost-devel gettext \
liblastfm-devel libgstreamer-devel libgstreamer-plugins-base-devel \
libglew-devel libqjson-devel libgpod-devel \
libplist-devel libmtp-devel libusbmuxd-devel qt4-linguist libcdio-devel \
fftw3-devel sqlite-devel"
On Pardus:
sudo pisi it boost-devel gettext-devel gstreamer-devel liblastfm-devel \
taglib-devel qt-devel cmake gst-plugins-base-devel glew-devel \
libqjson-devel libgpod-devel libplist-devel \
usbmuxd-devel libmtp-devel glibc-devel pkgconfig \
libxml2-devel libusb-devel glib2-devel sqlite-devel \
libcdio-devel libX11-devel kernel-headers zlib-devel fftw3-devel
### Compiling
This is the easy bit!
mkdir bin
cd bin
cmake ../
make
sudo make install
If you wish to have debug symbols, use
cmake -DCMAKE_BUILD_TYPE=Debug ../
instead of
cmake ../
It's a good idea to run cmake from a **separate build directory**. There's a `bin` directory provided for you. This is a good idea because it avoids cluttering the source directories with generated files, and it lets you completely wipe the build files with `rm -rf bin/*`.