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