deadbeef: add -with-plugins wrapper and a necessary patch
This commit is contained in:
parent
4a12ff77cc
commit
1a22ad6b18
3 changed files with 34 additions and 2 deletions
|
@ -1,4 +1,4 @@
|
|||
{ stdenv, fetchurl, intltool, pkgconfig
|
||||
{ stdenv, fetchurl, intltool, pkgconfig, fetchpatch
|
||||
# deadbeef can use either gtk2 or gtk3
|
||||
, gtk2Support ? true, gtk2 ? null
|
||||
, gtk3Support ? false, gtk3 ? null, gsettings_desktop_schemas ? null, makeWrapper ? null
|
||||
|
@ -51,7 +51,7 @@ stdenv.mkDerivation rec {
|
|||
name = "deadbeef-0.6.2";
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://garr.dl.sourceforge.net/project/deadbeef/${name}.tar.bz2";
|
||||
url = "mirror://sourceforge/project/deadbeef/${name}.tar.bz2";
|
||||
sha256 = "06jfsqyakpvq0xhah7dlyvdzh5ym3hhb4yfczczw11ijd1kbjcrl";
|
||||
};
|
||||
|
||||
|
@ -82,6 +82,12 @@ stdenv.mkDerivation rec {
|
|||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
patches = [ (fetchpatch {
|
||||
url = "https://github.com/Alexey-Yakovenko/deadbeef/commit/e7725ea73fa1bd279a3651704870156bca8efea8.patch";
|
||||
sha256 = "0a04l2607y3swcq9b1apffl1chdwj38jwfiizxcfmdbia4a0qlyg";
|
||||
})
|
||||
];
|
||||
|
||||
postInstall = if !gtk3Support then "" else ''
|
||||
wrapProgram "$out/bin/deadbeef" \
|
||||
--prefix XDG_DATA_DIRS : "$GSETTINGS_SCHEMAS_PATH"
|
||||
|
|
22
pkgs/applications/audio/deadbeef/wrapper.nix
Normal file
22
pkgs/applications/audio/deadbeef/wrapper.nix
Normal file
|
@ -0,0 +1,22 @@
|
|||
{ stdenv, buildEnv, deadbeef, makeWrapper, plugins }:
|
||||
|
||||
let
|
||||
drv = buildEnv {
|
||||
name = "deadbeef-with-plugins-" + (builtins.parseDrvName deadbeef.name).version;
|
||||
|
||||
paths = [ deadbeef ] ++ plugins;
|
||||
|
||||
postBuild = ''
|
||||
# TODO: This could be avoided if buildEnv could be forced to create all directories
|
||||
if [ -L $out/bin ]; then
|
||||
rm $out/bin
|
||||
mkdir $out/bin
|
||||
for i in ${deadbeef}/bin/*; do
|
||||
ln -s $i $out/bin
|
||||
done
|
||||
fi
|
||||
wrapProgram $out/bin/deadbeef \
|
||||
--set DEADBEEF_PLUGIN_DIR "$out/lib/deadbeef"
|
||||
'';
|
||||
};
|
||||
in stdenv.lib.overrideDerivation drv (x : { buildInputs = x.buildInputs ++ [ makeWrapper ]; })
|
|
@ -11011,6 +11011,10 @@ let
|
|||
|
||||
deadbeef-mpris2-plugin = callPackage ../applications/audio/deadbeef/plugins/mpris2.nix { };
|
||||
|
||||
deadbeef-with-plugins = callPackage ../applications/audio/deadbeef/wrapper.nix {
|
||||
plugins = [];
|
||||
};
|
||||
|
||||
dfasma = callPackage ../applications/audio/dfasma { };
|
||||
|
||||
dia = callPackage ../applications/graphics/dia {
|
||||
|
|
Loading…
Reference in a new issue