2014-11-17 17:04:16 +01:00
|
|
|
{ stdenv, fetchurl, cmake, pkgconfig, attica, boost, gnutls, libechonest
|
2016-04-22 15:11:10 +02:00
|
|
|
, liblastfm, lucenepp, phonon, phonon-backend-vlc, qca2, qjson, qt4
|
2014-12-10 10:26:42 +01:00
|
|
|
, qtkeychain, quazip, sparsehash, taglib, websocketpp, makeWrapper
|
2014-11-17 17:04:16 +01:00
|
|
|
|
|
|
|
, enableXMPP ? true, libjreen ? null
|
2017-02-25 00:16:28 +01:00
|
|
|
, enableKDE ? false, kdelibs4 ? null
|
2014-11-17 17:04:16 +01:00
|
|
|
, enableTelepathy ? false, telepathy_qt ? null
|
|
|
|
}:
|
|
|
|
|
|
|
|
assert enableXMPP -> libjreen != null;
|
2017-02-25 00:16:28 +01:00
|
|
|
assert enableKDE -> kdelibs4 != null;
|
2014-11-17 17:04:16 +01:00
|
|
|
assert enableTelepathy -> telepathy_qt != null;
|
|
|
|
|
2015-12-20 06:29:41 +01:00
|
|
|
stdenv.mkDerivation rec {
|
2014-11-17 17:04:16 +01:00
|
|
|
name = "tomahawk-${version}";
|
2015-09-14 20:39:32 +02:00
|
|
|
version = "0.8.4";
|
2014-11-17 17:04:16 +01:00
|
|
|
|
|
|
|
src = fetchurl {
|
2014-12-09 09:50:53 +01:00
|
|
|
url = "http://download.tomahawk-player.org/${name}.tar.bz2";
|
2015-09-14 20:39:32 +02:00
|
|
|
sha256 = "0j84h36wkjfjbsd7ybyji7rcc9wpjdbl0f1xdcc1g7h0nz34pc0g";
|
2014-11-17 17:04:16 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
cmakeFlags = [
|
|
|
|
"-DLUCENEPP_INCLUDE_DIR=${lucenepp}/include"
|
|
|
|
"-DLUCENEPP_LIBRARY_DIR=${lucenepp}/lib"
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
cmake pkgconfig attica boost gnutls libechonest liblastfm lucenepp phonon
|
2015-12-20 06:29:41 +01:00
|
|
|
qca2 qjson qt4 qtkeychain quazip sparsehash taglib websocketpp
|
2014-12-09 09:52:31 +01:00
|
|
|
makeWrapper
|
2014-11-17 17:04:16 +01:00
|
|
|
] ++ stdenv.lib.optional enableXMPP libjreen
|
2017-02-25 00:16:28 +01:00
|
|
|
++ stdenv.lib.optional enableKDE kdelibs4
|
2014-11-17 17:04:16 +01:00
|
|
|
++ stdenv.lib.optional enableTelepathy telepathy_qt;
|
|
|
|
|
2014-12-09 09:52:31 +01:00
|
|
|
postInstall = let
|
2014-12-10 10:26:42 +01:00
|
|
|
pluginPath = stdenv.lib.concatStringsSep ":" [
|
2016-04-22 15:11:10 +02:00
|
|
|
"${phonon-backend-vlc}/lib/kde4/plugins"
|
2014-12-10 10:26:42 +01:00
|
|
|
];
|
2014-12-09 09:52:31 +01:00
|
|
|
in ''
|
|
|
|
for i in "$out"/bin/*; do
|
|
|
|
wrapProgram "$i" --prefix QT_PLUGIN_PATH : "${pluginPath}"
|
|
|
|
done
|
|
|
|
'';
|
2014-11-22 05:02:08 +01:00
|
|
|
|
2014-11-17 17:04:16 +01:00
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "A multi-source music player";
|
|
|
|
homepage = "http://tomahawk-player.org/";
|
|
|
|
license = licenses.gpl3Plus;
|
|
|
|
platforms = platforms.all;
|
|
|
|
maintainers = [ maintainers.aszlig ];
|
|
|
|
};
|
|
|
|
}
|