2011-03-18 05:55:37 +00:00
|
|
|
{ stdenv, fetchurl, perlSupport, libX11, libXt, libXft, ncurses, perl,
|
2013-07-26 14:03:18 +01:00
|
|
|
fontconfig, freetype, pkgconfig, libXrender, gdkPixbufSupport, gdk_pixbuf }:
|
2010-07-28 19:01:17 +01:00
|
|
|
|
2013-09-27 21:30:49 +01:00
|
|
|
let
|
2009-09-10 17:57:47 +01:00
|
|
|
name = "rxvt-unicode";
|
2013-01-11 17:28:52 +00:00
|
|
|
version = "9.16";
|
2009-09-10 17:57:47 +01:00
|
|
|
n = "${name}-${version}";
|
|
|
|
in
|
2010-07-28 19:01:17 +01:00
|
|
|
|
2009-09-10 17:57:47 +01:00
|
|
|
stdenv.mkDerivation (rec {
|
2008-02-17 18:40:53 +00:00
|
|
|
|
2009-09-10 17:57:47 +01:00
|
|
|
name = "${n}${if perlSupport then "-with-perl" else ""}";
|
2008-02-17 18:40:53 +00:00
|
|
|
|
2009-09-10 17:57:47 +01:00
|
|
|
src = fetchurl {
|
2011-03-18 05:55:37 +00:00
|
|
|
url = "http://dist.schmorp.de/rxvt-unicode/Attic/rxvt-unicode-${version}.tar.bz2";
|
2013-01-11 17:28:52 +00:00
|
|
|
sha256 = "0x28wyslqnhn2q11y4hncqdl07wgh5ypywl92fq0jxycr36ibfvn";
|
2007-10-31 12:17:14 +00:00
|
|
|
};
|
2008-02-17 18:40:53 +00:00
|
|
|
|
2010-07-28 19:01:17 +01:00
|
|
|
buildInputs =
|
2013-09-27 21:30:49 +01:00
|
|
|
[ libX11 libXt libXft ncurses /* required to build the terminfo file */
|
2011-03-18 05:55:37 +00:00
|
|
|
fontconfig freetype pkgconfig libXrender ]
|
2013-07-26 14:03:18 +01:00
|
|
|
++ stdenv.lib.optional perlSupport perl
|
|
|
|
++ stdenv.lib.optional gdkPixbufSupport gdk_pixbuf;
|
2009-06-30 22:45:15 +01:00
|
|
|
|
2013-10-09 08:02:13 +01:00
|
|
|
outputs = [ "out" "terminfo" ];
|
|
|
|
|
2014-02-03 13:30:29 +00:00
|
|
|
patches = [ ./rxvt-unicode-9.06-font-width.patch ];
|
|
|
|
|
2010-07-28 19:01:17 +01:00
|
|
|
preConfigure =
|
|
|
|
''
|
2013-10-09 08:02:13 +01:00
|
|
|
mkdir -p $terminfo/share/terminfo
|
|
|
|
configureFlags="--with-terminfo=$terminfo/share/terminfo --enable-256-color ${if perlSupport then "--enable-perl" else "--disable-perl"}";
|
|
|
|
export TERMINFO=$terminfo/share/terminfo # without this the terminfo won't be compiled by tic, see man tic
|
2011-03-18 05:55:37 +00:00
|
|
|
NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE -I${freetype}/include/freetype2"
|
|
|
|
NIX_LDFLAGS="$NIX_LDFLAGS -lfontconfig -lXrender "
|
2010-07-28 19:01:17 +01:00
|
|
|
''
|
|
|
|
# make urxvt find its perl file lib/perl5/site_perl is added to PERL5LIB automatically
|
|
|
|
+ stdenv.lib.optionalString perlSupport ''
|
2012-01-18 20:16:00 +00:00
|
|
|
mkdir -p $out/lib/perl5
|
2009-09-10 17:57:47 +01:00
|
|
|
ln -s $out/{lib/urxvt,lib/perl5/site_perl}
|
2010-07-28 19:01:17 +01:00
|
|
|
'';
|
2008-02-17 18:40:53 +00:00
|
|
|
|
2007-10-31 12:17:14 +00:00
|
|
|
meta = {
|
2010-07-28 19:01:17 +01:00
|
|
|
description = "A clone of the well-known terminal emulator rxvt";
|
2007-10-31 12:17:14 +00:00
|
|
|
homepage = "http://software.schmorp.de/pkg/rxvt-unicode.html";
|
2014-01-28 17:11:00 +00:00
|
|
|
maintainers = stdenv.lib.maintainers.mornfall;
|
2007-10-31 12:17:14 +00:00
|
|
|
};
|
2008-02-17 18:40:53 +00:00
|
|
|
})
|