diff --git a/pkgs/applications/networking/instant-messengers/profanity/default.nix b/pkgs/applications/networking/instant-messengers/profanity/default.nix index f36fd5c8130..2d75bf004b0 100644 --- a/pkgs/applications/networking/instant-messengers/profanity/default.nix +++ b/pkgs/applications/networking/instant-messengers/profanity/default.nix @@ -1,11 +1,15 @@ -{ stdenv, fetchurl, automake, autoconf, pkgconfig, glib, openssl, expat, ncurses, libotr, curl, libstrophe, -libnotifySupport ? false, libnotify ? null, libXScrnSaver ? null, libX11 ? null, gdk_pixbuf ? null}: +{ stdenv, fetchurl, automake, autoconf, pkgconfig, glib, openssl, expat +, ncurses, libotr, curl, libstrophe -assert libnotifySupport -> (libnotify != null && libXScrnSaver != null && libX11 != null && gdk_pixbuf != null); +, notifySupport ? false, libnotify ? null, libXScrnSaver ? null +, libX11 ? null, gdk_pixbuf ? null +}: + +assert notifySupport -> libnotify != null && libXScrnSaver != null + && libX11 != null && gdk_pixbuf != null; + +with stdenv.lib; -let - optional = stdenv.lib.optional; -in stdenv.mkDerivation rec { name = "profanity-${version}"; version = "0.4.5"; @@ -15,8 +19,10 @@ stdenv.mkDerivation rec { sha256 = "0qzwqxcxf695z3gf94psd2x619vlp4hkkjmkrpsla1ns0f6v6dkl"; }; - buildInputs = [ automake autoconf pkgconfig glib openssl expat ncurses libotr curl libstrophe ] - ++ optional libnotifySupport [ libnotify libXScrnSaver libX11 gdk_pixbuf ]; + buildInputs = [ + automake autoconf pkgconfig + glib openssl expat ncurses libotr curl libstrophe + ] ++ optionals notifySupport [ libnotify libXScrnSaver libX11 gdk_pixbuf ]; preConfigure = "sh bootstrap.sh"; @@ -27,8 +33,8 @@ stdenv.mkDerivation rec { libstrophe, inspired by Irssi. ''; homepage = http://profanity.im/; - license = stdenv.lib.licenses.gpl3Plus; - platforms = stdenv.lib.platforms.linux; - maintainers = [ stdenv.lib.maintainers.devhell ]; + license = licenses.gpl3Plus; + platforms = platforms.linux; + maintainers = [ maintainers.devhell ]; }; } diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 5da42fa5338..9acd92092f9 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -10580,7 +10580,7 @@ let procmail = callPackage ../applications/misc/procmail { }; profanity = callPackage ../applications/networking/instant-messengers/profanity { - libnotifySupport = config.profanity.libnotifySupport or true; + notifySupport = config.profanity.notifySupport or true; }; pstree = callPackage ../applications/misc/pstree { };