cantata clean up
This commit is contained in:
parent
14594db481
commit
a05f1e2ec4
@ -38,9 +38,10 @@ let
|
|||||||
pname = "cantata";
|
pname = "cantata";
|
||||||
fstat = x: fn: "-DENABLE_" + fn + "=" + (if x then "ON" else "OFF");
|
fstat = x: fn: "-DENABLE_" + fn + "=" + (if x then "ON" else "OFF");
|
||||||
fstats = x: map (fstat x);
|
fstats = x: map (fstat x);
|
||||||
in
|
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
withUdisks = (withTaglib && withDevices);
|
||||||
|
|
||||||
|
in stdenv.mkDerivation rec {
|
||||||
name = "${pname}-${version}";
|
name = "${pname}-${version}";
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
@ -60,35 +61,30 @@ stdenv.mkDerivation rec {
|
|||||||
++ stdenv.lib.optional withLame lame
|
++ stdenv.lib.optional withLame lame
|
||||||
++ stdenv.lib.optional withMtp libmtp
|
++ stdenv.lib.optional withMtp libmtp
|
||||||
++ stdenv.lib.optional withMusicbrainz libmusicbrainz5
|
++ stdenv.lib.optional withMusicbrainz libmusicbrainz5
|
||||||
++ stdenv.lib.optional (withTaglib && withDevices) udisks2;
|
++ stdenv.lib.optional withUdisks udisks2;
|
||||||
|
|
||||||
nativeBuildInputs = [ cmake pkgconfig ];
|
nativeBuildInputs = [ cmake pkgconfig ];
|
||||||
|
|
||||||
enableParallelBuilding = true;
|
enableParallelBuilding = true;
|
||||||
|
|
||||||
cmakeFlags = stdenv.lib.flatten [
|
cmakeFlags = stdenv.lib.flatten [
|
||||||
(fstat withQt5 "QT5")
|
(fstat withQt5 "QT5")
|
||||||
(fstats withTaglib [ "TAGLIB" "TAGLIB_EXTRAS" ])
|
(fstats withTaglib [ "TAGLIB" "TAGLIB_EXTRAS" ])
|
||||||
(fstats withReplaygain [ "FFMPEG" "MPG123" "SPEEXDSP" ])
|
(fstats withReplaygain [ "FFMPEG" "MPG123" "SPEEXDSP" ])
|
||||||
(fstat withCdda "CDPARANOIA")
|
(fstat withCdda "CDPARANOIA")
|
||||||
(fstat withCddb "CDDB")
|
(fstat withCddb "CDDB")
|
||||||
(fstat withLame "LAME")
|
(fstat withLame "LAME")
|
||||||
(fstat withMtp "MTP")
|
(fstat withMtp "MTP")
|
||||||
(fstat withMusicbrainz "MUSICBRAINZ")
|
(fstat withMusicbrainz "MUSICBRAINZ")
|
||||||
(fstat withOnlineServices "ONLINE_SERVICES")
|
(fstat withOnlineServices "ONLINE_SERVICES")
|
||||||
(fstat withDynamic "DYNAMIC")
|
(fstat withDynamic "DYNAMIC")
|
||||||
(fstat withDevices "DEVICES_SUPPORT")
|
(fstat withDevices "DEVICES_SUPPORT")
|
||||||
(fstat withHttpServer "HTTP_SERVER")
|
(fstat withHttpServer "HTTP_SERVER")
|
||||||
(fstat withStreams "STREAMS")
|
(fstat withStreams "STREAMS")
|
||||||
|
(fstat withUdisks "UDISKS2")
|
||||||
"-DENABLE_HTTPS_SUPPORT=ON"
|
"-DENABLE_HTTPS_SUPPORT=ON"
|
||||||
"-DENABLE_UDISKS2=ON"
|
|
||||||
];
|
];
|
||||||
|
|
||||||
# This is already fixed upstream but not released yet. Maybe in version 2.
|
|
||||||
preConfigure = ''
|
|
||||||
# sed -i -e 's/STRLESS/VERSION_LESS/g' cmake/FindTaglib.cmake
|
|
||||||
'';
|
|
||||||
|
|
||||||
meta = with stdenv.lib; {
|
meta = with stdenv.lib; {
|
||||||
homepage = https://github.com/cdrummond/cantata;
|
homepage = https://github.com/cdrummond/cantata;
|
||||||
description = "A graphical client for MPD";
|
description = "A graphical client for MPD";
|
||||||
|
Loading…
Reference in New Issue
Block a user