8eafd21f9e
Needed to patch package xineLib to fix usage of XINE_PLUGIN_PATH .
30 lines
813 B
Nix
30 lines
813 B
Nix
{ symlinkJoin, lib, makeWrapper, vdr
|
|
, plugins ? []
|
|
}: let
|
|
|
|
makeXinePluginPath = l: lib.concatStringsSep ":" (map (p: "${p}/lib/xine/plugins") l);
|
|
|
|
requiredXinePlugins = lib.flatten (map (p: p.passthru.requiredXinePlugins or []) plugins);
|
|
|
|
in symlinkJoin {
|
|
|
|
name = "vdr-with-plugins-${(builtins.parseDrvName vdr.name).version}";
|
|
|
|
paths = [ vdr ] ++ plugins;
|
|
|
|
nativeBuildInputs = [ makeWrapper ];
|
|
|
|
postBuild = ''
|
|
wrapProgram $out/bin/vdr \
|
|
--add-flags "-L $out/lib/vdr --localedir=$out/share/locale" \
|
|
--prefix XINE_PLUGIN_PATH ":" ${makeXinePluginPath requiredXinePlugins}
|
|
'';
|
|
|
|
meta = with vdr.meta; {
|
|
inherit license homepage;
|
|
description = description
|
|
+ " (with plugins: "
|
|
+ lib.concatStrings (lib.intersperse ", " (map (x: ""+x.name) plugins))
|
|
+ ")";
|
|
};
|
|
}
|