2023-08-04 22:07:22 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, vdr
|
|
|
|
, fetchFromGitHub
|
|
|
|
, ffmpeg
|
|
|
|
}:
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "vdr-markad";
|
2024-05-15 15:35:15 +00:00
|
|
|
version = "3.6.0";
|
2023-08-04 22:07:22 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
repo = "vdr-plugin-markad";
|
|
|
|
owner = "kfb77";
|
2024-05-15 15:35:15 +00:00
|
|
|
sha256 = "sha256-O958GNQI6Z+m4sIJfGQzLaCrzyrdpn+ZY8COx7RoUZs=";
|
2023-08-04 22:07:22 +00:00
|
|
|
rev = "V${version}";
|
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [ vdr ffmpeg ];
|
|
|
|
|
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace command/Makefile --replace '/usr' ""
|
|
|
|
|
|
|
|
substituteInPlace plugin/markad.cpp \
|
|
|
|
--replace "/usr/bin" "$out/bin" \
|
|
|
|
--replace "/var/lib/markad" "$out/var/lib/markad"
|
|
|
|
|
|
|
|
substituteInPlace command/markad-standalone.cpp \
|
|
|
|
--replace "/var/lib/markad" "$out/var/lib/markad"
|
|
|
|
'';
|
|
|
|
|
|
|
|
buildFlags = [
|
|
|
|
"DESTDIR=$(out)"
|
|
|
|
"VDRDIR=${vdr.dev}/lib/pkgconfig"
|
|
|
|
];
|
|
|
|
|
|
|
|
installFlags = buildFlags;
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
inherit (src.meta) homepage;
|
|
|
|
description = "Plugin for VDR that marks advertisements";
|
2024-04-21 15:54:59 +00:00
|
|
|
mainProgram = "markad";
|
2023-08-04 22:07:22 +00:00
|
|
|
maintainers = [ maintainers.ck3d ];
|
|
|
|
license = licenses.gpl2;
|
|
|
|
inherit (vdr.meta) platforms;
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|