depot/third_party/nixpkgs/pkgs/applications/audio/mympd/default.nix
Default email 9c6ee729d6 Project import generated by Copybara.
GitOrigin-RevId: 6cee3b5893090b0f5f0a06b4cf42ca4e60e5d222
2023-07-15 19:15:38 +02:00

68 lines
1.3 KiB
Nix

{ lib
, stdenv
, fetchFromGitHub
, cmake
, pkg-config
, libmpdclient
, openssl
, lua5_3
, libid3tag
, flac
, pcre2
, gzip
, perl
, jq
}:
stdenv.mkDerivation rec {
pname = "mympd";
version = "10.3.3";
src = fetchFromGitHub {
owner = "jcorporation";
repo = "myMPD";
rev = "v${version}";
sha256 = "sha256-LqIaRFAXB3XMidC1Dypax/ucayot/IJPAvPwzHQeH9k=";
};
nativeBuildInputs = [
pkg-config
cmake
gzip
perl
jq
];
preConfigure = ''
env MYMPD_BUILDDIR=$PWD/build ./build.sh createassets
'';
buildInputs = [
libmpdclient
openssl
lua5_3
libid3tag
flac
pcre2
];
cmakeFlags = [
"-DENABLE_LUA=ON"
# Otherwise, it tries to parse $out/etc/mympd.conf on startup.
"-DCMAKE_INSTALL_SYSCONFDIR=/etc"
# similarly here
"-DCMAKE_INSTALL_LOCALSTATEDIR=/var/lib/mympd"
];
hardeningDisable = [
# See https://github.com/jcorporation/myMPD/issues/315
"strictoverflow"
# causes redefinition of _FORTIFY_SOURCE
"fortify3"
];
meta = {
homepage = "https://jcorporation.github.io/myMPD";
description = "A standalone and mobile friendly web mpd client with a tiny footprint and advanced features";
maintainers = [ lib.maintainers.doronbehar ];
platforms = lib.platforms.linux;
license = lib.licenses.gpl2Plus;
};
}