2021-01-15 08:07:56 +01:00
|
|
|
{ lib, stdenv, fetchurl, pcre }:
|
2014-04-15 09:54:58 +02:00
|
|
|
|
2019-08-13 23:52:01 +02:00
|
|
|
stdenv.mkDerivation {
|
2021-07-25 23:53:02 +02:00
|
|
|
pname = "leafnode";
|
|
|
|
version = "2.0.0.alpha20121101a.12";
|
2014-04-15 09:54:58 +02:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "http://home.pages.de/~mandree/leafnode/beta/leafnode-2.0.0.alpha20121101a.tar.bz2";
|
|
|
|
sha256 = "096w4gxj08m3vwmyv4sxpmbl8dn6mzqfmrhc32jgyca6qzlrdin8";
|
|
|
|
};
|
|
|
|
|
2018-07-25 23:44:21 +02:00
|
|
|
configureFlags = [ "--enable-runas-user=nobody" ];
|
2014-04-15 09:54:58 +02:00
|
|
|
|
2017-06-28 21:26:24 +02:00
|
|
|
prePatch = ''
|
|
|
|
substituteInPlace Makefile.in --replace 02770 0770
|
|
|
|
'';
|
|
|
|
|
2014-09-04 22:45:55 +02:00
|
|
|
preConfigure = ''
|
|
|
|
# configure uses id to check environment; we don't want this check
|
|
|
|
sed -re 's/^ID[=].*/ID="echo whatever"/' -i configure
|
|
|
|
'';
|
|
|
|
|
2014-04-15 09:54:58 +02:00
|
|
|
postConfigure = ''
|
|
|
|
# The is_validfqdn is far too restrictive, and only allows
|
|
|
|
# Internet-facing servers to run. In order to run leafnode via
|
|
|
|
# localhost only, we need to disable this check.
|
|
|
|
sed -i validatefqdn.c -e 's/int is_validfqdn(const char \*f) {/int is_validfqdn(const char *f) { return 1;/;'
|
|
|
|
'';
|
|
|
|
|
|
|
|
buildInputs = [ pcre];
|
|
|
|
|
|
|
|
meta = {
|
2020-04-01 03:11:51 +02:00
|
|
|
homepage = "http://leafnode.sourceforge.net/";
|
2020-10-26 05:08:40 +01:00
|
|
|
description = "Implementation of a store & forward NNTP proxy";
|
2021-01-15 08:07:56 +01:00
|
|
|
license = lib.licenses.mit;
|
|
|
|
platforms = lib.platforms.unix;
|
2014-04-15 09:54:58 +02:00
|
|
|
};
|
|
|
|
}
|