2006-04-28 19:02:52 +00:00
|
|
|
{ stdenv, fetchurl
|
|
|
|
, sslSupport ? true
|
|
|
|
, graphicsSupport ? false
|
2009-10-28 15:06:18 +00:00
|
|
|
, ncurses, openssl ? null, boehmgc, gettext, zlib
|
|
|
|
, imlib2 ? null, x11 ? null
|
2005-09-14 16:23:02 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
assert sslSupport -> openssl != null;
|
2009-10-28 15:06:18 +00:00
|
|
|
assert graphicsSupport -> x11 != null;
|
2005-09-14 16:23:02 +00:00
|
|
|
|
2011-04-30 09:20:59 +00:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "w3m-0.5.3";
|
2008-11-14 11:16:54 +00:00
|
|
|
|
2005-09-14 16:23:02 +00:00
|
|
|
src = fetchurl {
|
2011-04-30 09:20:59 +00:00
|
|
|
url = "mirror://sourceforge/w3m/${name}.tar.gz";
|
|
|
|
sha256 = "1qx9f0kprf92r1wxl3sacykla0g04qsi0idypzz24b7xy9ix5579";
|
2005-09-14 16:23:02 +00:00
|
|
|
};
|
2008-11-14 11:16:54 +00:00
|
|
|
|
2010-09-02 20:09:27 +00:00
|
|
|
# Patch for the newer unstable boehm-gc 7.2alpha. Not all platforms use that
|
|
|
|
# alpha. At the time of writing this, boehm-gc-7.1 is the last stable.
|
|
|
|
patches = stdenv.lib.optional (boehmgc.name != "boehm-gc-7.1") [ ./newgc.patch ];
|
2010-08-21 17:07:03 +00:00
|
|
|
|
2008-11-14 11:16:54 +00:00
|
|
|
buildInputs = [ncurses boehmgc gettext zlib]
|
|
|
|
++ stdenv.lib.optional sslSupport openssl
|
2009-10-28 15:06:18 +00:00
|
|
|
++ stdenv.lib.optionals graphicsSupport [imlib2 x11];
|
2008-11-14 11:16:54 +00:00
|
|
|
|
|
|
|
configureFlags = "--with-ssl=${openssl} --with-gc=${boehmgc}";
|
|
|
|
|
|
|
|
preConfigure = ''
|
|
|
|
substituteInPlace ./configure --replace /usr /no-such-path
|
|
|
|
'';
|
2008-01-30 19:49:42 +00:00
|
|
|
|
|
|
|
meta = {
|
2008-11-14 11:16:54 +00:00
|
|
|
homepage = http://w3m.sourceforge.net/;
|
|
|
|
description = "A text-mode web browser";
|
2008-01-30 19:49:42 +00:00
|
|
|
};
|
2005-09-14 16:23:02 +00:00
|
|
|
}
|