2021-02-12 11:35:49 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, fetchurl
|
2022-12-07 16:11:29 +00:00
|
|
|
, fetchpatch
|
2021-02-12 11:35:49 +00:00
|
|
|
, pkg-config
|
|
|
|
, meson
|
|
|
|
, ninja
|
|
|
|
, boost
|
|
|
|
, curl
|
|
|
|
, libgcrypt
|
|
|
|
, libmpdclient
|
|
|
|
, systemd
|
|
|
|
}:
|
2015-03-14 10:47:11 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 12:41:18 +00:00
|
|
|
pname = "mpdscribble";
|
2022-03-18 12:38:17 +00:00
|
|
|
version = "0.24";
|
2015-03-14 10:47:11 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
2021-02-12 11:35:49 +00:00
|
|
|
url = "https://www.musicpd.org/download/mpdscribble/${version}/mpdscribble-${version}.tar.xz";
|
2022-03-18 12:38:17 +00:00
|
|
|
sha256 = "sha256-9rTLp0izuH5wUnC0kjyOI+lMLgD+3VC+sUaNvi+yqOc=";
|
2015-03-14 10:47:11 +00:00
|
|
|
};
|
|
|
|
|
2022-12-07 16:11:29 +00:00
|
|
|
# Fix build issue on darwin; to be removed after the next release
|
|
|
|
patches = [(fetchpatch {
|
|
|
|
name = "remove-empty-static-lib.patch";
|
|
|
|
url = "https://github.com/MusicPlayerDaemon/mpdscribble/commit/0dbcea25c81f3fdc608f71ef71a9784679fee17f.patch";
|
|
|
|
sha256 = "sha256-3wLfQvbwx+OFrCl5vMV7Zps4e4iEYFhqPiVCo5hDqgw=";
|
|
|
|
})];
|
|
|
|
|
2023-02-05 17:34:47 +00:00
|
|
|
postPatch = ''
|
|
|
|
sed '1i#include <ctime>' -i src/Log.cxx # gcc12
|
|
|
|
'';
|
|
|
|
|
2021-02-12 11:35:49 +00:00
|
|
|
nativeBuildInputs = [ pkg-config meson ninja ];
|
|
|
|
buildInputs = [
|
|
|
|
libmpdclient
|
|
|
|
curl
|
|
|
|
boost
|
|
|
|
libgcrypt
|
2022-12-07 16:11:29 +00:00
|
|
|
] ++ lib.optional stdenv.isLinux systemd;
|
2015-03-14 10:47:11 +00:00
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2021-02-12 11:35:49 +00:00
|
|
|
description = "A MPD client which submits info about tracks being played to a scrobbler";
|
2020-04-01 01:11:51 +00:00
|
|
|
homepage = "https://www.musicpd.org/clients/mpdscribble/";
|
2021-02-12 11:35:49 +00:00
|
|
|
license = licenses.gpl2Plus;
|
2020-09-09 13:29:05 +00:00
|
|
|
maintainers = [ maintainers.sohalt ];
|
2022-12-07 16:11:29 +00:00
|
|
|
platforms = platforms.unix;
|
2015-03-14 10:47:11 +00:00
|
|
|
};
|
|
|
|
}
|