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