make a wrapper so that dunst can find dbus-launch

Prior to this change, the following would fail
nix-shell --pure -p dunst --command dunst
while this would succeed
nix-shell --pure -p dunst -p dbus_daemon --command dunst

because dunst tries to execve 'dbus-launch'. The same issue hit if dunst
was used inside a (user) systemd service (which is what I actually care
about).

+10 -4
+10 -4
pkgs/applications/misc/dunst/default.nix
··· 1 - { stdenv, fetchurl, coreutils , unzip, which, pkgconfig , dbus 2 - , freetype, xdg_utils , libXext, glib, pango , cairo, libX11, libnotify 3 - , libxdg_basedir , libXScrnSaver, xproto, libXinerama , perl, gdk_pixbuf 4 }: 5 6 stdenv.mkDerivation rec { ··· 15 buildInputs = 16 [ coreutils unzip which pkgconfig dbus freetype libnotify gdk_pixbuf 17 xdg_utils libXext glib pango cairo libX11 libxdg_basedir 18 - libXScrnSaver xproto libXinerama perl]; 19 20 buildPhase = '' 21 export VERSION=${version}; 22 export PREFIX=$out; 23 make dunst; 24 ''; 25 26 meta = {
··· 1 + { stdenv, fetchurl, coreutils, unzip, which, pkgconfig, dbus 2 + , freetype, xdg_utils, libXext, glib, pango, cairo, libX11, libnotify 3 + , libxdg_basedir, libXScrnSaver, xproto, libXinerama, perl, gdk_pixbuf 4 + , dbus_daemon, makeWrapper 5 }: 6 7 stdenv.mkDerivation rec { ··· 16 buildInputs = 17 [ coreutils unzip which pkgconfig dbus freetype libnotify gdk_pixbuf 18 xdg_utils libXext glib pango cairo libX11 libxdg_basedir 19 + libXScrnSaver xproto libXinerama perl dbus_daemon makeWrapper ]; 20 21 buildPhase = '' 22 export VERSION=${version}; 23 export PREFIX=$out; 24 make dunst; 25 + ''; 26 + 27 + postFixup = '' 28 + wrapProgram "$out/bin/dunst" \ 29 + --prefix PATH : '${dbus_daemon}/bin' 30 ''; 31 32 meta = {