From 429dd8e8847c87b264430a08c5275500ed104750 Mon Sep 17 00:00:00 2001 From: "dev.hell" Date: Sun, 4 Jan 2015 23:46:10 +0000 Subject: [PATCH] profanity: Add libnotifySupport config option This adds support for profanity to be optionally built with libnotify. --- .../instant-messengers/profanity/default.nix | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/networking/instant-messengers/profanity/default.nix b/pkgs/applications/networking/instant-messengers/profanity/default.nix index b6e78eb7a000..f36fd5c8130a 100644 --- a/pkgs/applications/networking/instant-messengers/profanity/default.nix +++ b/pkgs/applications/networking/instant-messengers/profanity/default.nix @@ -1,5 +1,11 @@ -{ stdenv, fetchurl, automake, autoconf, pkgconfig, glib, openssl, expat, ncurses, libnotify, libotr, curl, libstrophe, libXScrnSaver, libX11 }: +{ stdenv, fetchurl, automake, autoconf, pkgconfig, glib, openssl, expat, ncurses, libotr, curl, libstrophe, +libnotifySupport ? false, libnotify ? null, libXScrnSaver ? null, libX11 ? null, gdk_pixbuf ? null}: +assert libnotifySupport -> (libnotify != null && libXScrnSaver != null && libX11 != null && gdk_pixbuf != null); + +let + optional = stdenv.lib.optional; +in stdenv.mkDerivation rec { name = "profanity-${version}"; version = "0.4.5"; @@ -9,7 +15,8 @@ stdenv.mkDerivation rec { sha256 = "0qzwqxcxf695z3gf94psd2x619vlp4hkkjmkrpsla1ns0f6v6dkl"; }; - buildInputs = [ automake autoconf pkgconfig glib openssl expat ncurses libnotify libotr curl libstrophe libXScrnSaver libX11 ]; + buildInputs = [ automake autoconf pkgconfig glib openssl expat ncurses libotr curl libstrophe ] + ++ optional libnotifySupport [ libnotify libXScrnSaver libX11 gdk_pixbuf ]; preConfigure = "sh bootstrap.sh";