2021-01-11 07:54:33 +00:00
|
|
|
{ lib, stdenv, fetchFromGitHub, fetchpatch, ncurses, xlibsWrapper, bzip2, zlib
|
2021-03-14 18:12:53 +00:00
|
|
|
, brotli, zstd, xz, openssl, autoreconfHook, gettext, pkg-config, libev
|
2020-10-10 15:18:53 +01:00
|
|
|
, gpm, libidn, tre, expat
|
2017-09-05 18:11:27 +01:00
|
|
|
, # Incompatible licenses, LGPLv3 - GPLv2
|
|
|
|
enableGuile ? false, guile ? null
|
|
|
|
, enablePython ? false, python ? null
|
|
|
|
, enablePerl ? (stdenv.hostPlatform == stdenv.buildPlatform), perl ? null
|
2020-10-10 15:18:53 +01:00
|
|
|
# re-add javascript support when upstream supports modern spidermonkey
|
2014-01-20 08:27:27 +00:00
|
|
|
}:
|
2013-03-15 10:50:09 +00:00
|
|
|
|
|
|
|
assert enableGuile -> guile != null;
|
2014-01-20 08:27:27 +00:00
|
|
|
assert enablePython -> python != null;
|
2007-07-17 20:29:53 +01:00
|
|
|
|
2020-06-26 22:59:28 +01:00
|
|
|
stdenv.mkDerivation rec {
|
2020-10-10 15:18:53 +01:00
|
|
|
pname = "elinks";
|
2021-05-31 04:04:33 +01:00
|
|
|
version = "0.14.1";
|
2020-10-10 15:18:53 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "rkd77";
|
|
|
|
repo = "felinks";
|
|
|
|
rev = "v${version}";
|
2021-05-31 04:04:33 +01:00
|
|
|
sha256 = "sha256-D7dUVHgYGzY4FXEnOzXw0Fao3gLgfFuCl8LJdLVpcSM=";
|
2007-07-17 20:29:53 +01:00
|
|
|
};
|
|
|
|
|
2020-10-10 15:18:53 +01:00
|
|
|
buildInputs = [
|
2021-03-14 18:12:53 +00:00
|
|
|
ncurses xlibsWrapper bzip2 zlib brotli zstd xz
|
2020-10-10 15:18:53 +01:00
|
|
|
openssl libidn tre expat libev
|
|
|
|
]
|
2021-01-15 13:21:58 +00:00
|
|
|
++ lib.optional stdenv.isLinux gpm
|
|
|
|
++ lib.optional enableGuile guile
|
|
|
|
++ lib.optional enablePython python
|
|
|
|
++ lib.optional enablePerl perl
|
2017-09-05 18:11:27 +01:00
|
|
|
;
|
2020-09-30 15:00:56 +01:00
|
|
|
|
2021-01-19 06:50:56 +00:00
|
|
|
nativeBuildInputs = [ autoreconfHook gettext pkg-config ];
|
2017-09-05 18:11:27 +01:00
|
|
|
|
|
|
|
configureFlags = [
|
|
|
|
"--enable-finger"
|
|
|
|
"--enable-html-highlight"
|
|
|
|
"--enable-gopher"
|
|
|
|
"--enable-cgi"
|
|
|
|
"--enable-bittorrent"
|
|
|
|
"--enable-nntp"
|
2020-06-16 10:04:10 +01:00
|
|
|
"--enable-256-colors"
|
2020-10-10 15:18:53 +01:00
|
|
|
"--enable-true-color"
|
|
|
|
"--with-lzma"
|
2020-06-16 10:04:10 +01:00
|
|
|
"--with-libev"
|
2020-10-10 15:18:53 +01:00
|
|
|
"--with-terminfo"
|
2021-01-15 13:21:58 +00:00
|
|
|
] ++ lib.optional enableGuile "--with-guile"
|
|
|
|
++ lib.optional enablePython "--with-python"
|
|
|
|
++ lib.optional enablePerl "--with-perl"
|
2017-09-05 18:11:27 +01:00
|
|
|
;
|
2020-09-30 15:00:56 +01:00
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2020-06-16 10:04:10 +01:00
|
|
|
description = "Full-featured text-mode web browser (package based on the fork felinks)";
|
|
|
|
homepage = "https://github.com/rkd77/felinks";
|
2020-06-26 22:59:28 +01:00
|
|
|
license = licenses.gpl2;
|
|
|
|
platforms = with platforms; linux ++ darwin;
|
2020-10-10 15:18:53 +01:00
|
|
|
maintainers = with maintainers; [ iblech gebner ];
|
2007-07-17 20:29:53 +01:00
|
|
|
};
|
|
|
|
}
|