2014-11-17 16:04:16 +00:00
|
|
|
{ stdenv, fetchurl, cmake, pkgconfig, attica, boost, gnutls, libechonest
|
2015-03-31 00:50:47 +01:00
|
|
|
, liblastfm, lucenepp, phonon, phonon_backend_vlc, qca2, qjson, qt4
|
2014-12-10 09:26:42 +00:00
|
|
|
, qtkeychain, quazip, sparsehash, taglib, websocketpp, makeWrapper
|
2014-11-17 16:04:16 +00:00
|
|
|
|
|
|
|
, enableXMPP ? true, libjreen ? null
|
|
|
|
, enableKDE ? false, kdelibs ? null
|
|
|
|
, enableTelepathy ? false, telepathy_qt ? null
|
|
|
|
}:
|
|
|
|
|
|
|
|
assert enableXMPP -> libjreen != null;
|
|
|
|
assert enableKDE -> kdelibs != null;
|
|
|
|
assert enableTelepathy -> telepathy_qt != null;
|
|
|
|
|
|
|
|
let
|
|
|
|
quazipQt4 = quazip.override { qt = qt4; };
|
|
|
|
in stdenv.mkDerivation rec {
|
|
|
|
name = "tomahawk-${version}";
|
2015-04-11 22:02:21 +01:00
|
|
|
version = "0.8.3";
|
2014-11-17 16:04:16 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
2014-12-09 08:50:53 +00:00
|
|
|
url = "http://download.tomahawk-player.org/${name}.tar.bz2";
|
2015-04-11 22:02:21 +01:00
|
|
|
sha256 = "0kjzkq21g3jl1lvadsm7gf0zvpbsv208kqf76wg2hnbm4k1a02wj";
|
2014-11-17 16:04:16 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
cmakeFlags = [
|
|
|
|
"-DLUCENEPP_INCLUDE_DIR=${lucenepp}/include"
|
|
|
|
"-DLUCENEPP_LIBRARY_DIR=${lucenepp}/lib"
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
cmake pkgconfig attica boost gnutls libechonest liblastfm lucenepp phonon
|
|
|
|
qca2 qjson qt4 qtkeychain quazipQt4 sparsehash taglib websocketpp
|
2014-12-09 08:52:31 +00:00
|
|
|
makeWrapper
|
2014-11-17 16:04:16 +00:00
|
|
|
] ++ stdenv.lib.optional enableXMPP libjreen
|
|
|
|
++ stdenv.lib.optional enableKDE kdelibs
|
|
|
|
++ stdenv.lib.optional enableTelepathy telepathy_qt;
|
|
|
|
|
2014-12-09 08:52:31 +00:00
|
|
|
postInstall = let
|
2014-12-10 09:26:42 +00:00
|
|
|
pluginPath = stdenv.lib.concatStringsSep ":" [
|
|
|
|
"${phonon_backend_vlc}/lib/kde4/plugins"
|
|
|
|
];
|
2014-12-09 08:52:31 +00:00
|
|
|
in ''
|
|
|
|
for i in "$out"/bin/*; do
|
|
|
|
wrapProgram "$i" --prefix QT_PLUGIN_PATH : "${pluginPath}"
|
|
|
|
done
|
|
|
|
'';
|
2014-11-22 04:02:08 +00:00
|
|
|
|
2014-11-17 16:04:16 +00: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 ];
|
|
|
|
};
|
|
|
|
}
|