nixpkgs/pkgs/applications/misc/girara/default.nix

46 lines
1.3 KiB
Nix
Raw Normal View History

2017-04-22 00:44:19 +02:00
{ stdenv, fetchurl, pkgconfig, gtk, gettext, ncurses, libiconv, libintlOrEmpty
2017-02-15 14:58:19 +01:00
, withBuildColors ? true
}:
assert withBuildColors -> ncurses != null;
stdenv.mkDerivation rec {
name = "girara-${version}";
2017-12-31 01:59:55 +01:00
version = "0.2.8";
src = fetchurl {
2017-02-15 14:58:19 +01:00
url = "http://pwmt.org/projects/girara/download/${name}.tar.gz";
2017-12-31 01:59:55 +01:00
sha256 = "18wss3sak3djip090v2vdbvq1mvkwcspfswc87zbvv3magihan98";
};
preConfigure = ''
2017-02-15 14:58:19 +01:00
substituteInPlace colors.mk \
--replace 'ifdef TPUT_AVAILABLE' 'ifneq ($(TPUT_AVAILABLE), 0)'
'';
nativeBuildInputs = [ pkgconfig ];
buildInputs = [ gtk gettext libintlOrEmpty ]
2017-04-22 00:44:19 +02:00
++ stdenv.lib.optional stdenv.isDarwin libiconv;
NIX_LDFLAGS = stdenv.lib.optionalString stdenv.isDarwin "-lintl";
2017-02-15 14:58:19 +01:00
makeFlags = [
"PREFIX=$(out)"
(if withBuildColors
then "TPUT=${ncurses.out}/bin/tput"
else "TPUT_AVAILABLE=0")
];
2017-02-15 14:58:19 +01:00
meta = with stdenv.lib; {
homepage = https://pwmt.org/projects/girara/;
description = "User interface library";
longDescription = ''
girara is a library that implements a GTK+ based VIM-like user interface
that focuses on simplicity and minimalism.
'';
license = licenses.zlib;
2017-04-22 00:44:19 +02:00
platforms = platforms.linux ++ platforms.darwin;
maintainers = [ maintainers.garbas ];
};
}