2021-01-15 09:19:50 +00:00
|
|
|
{ lib, stdenv, fetchurl, openssl }:
|
2009-03-02 15:23:52 +00:00
|
|
|
|
2014-04-08 21:13:08 +00:00
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 12:41:18 +00:00
|
|
|
pname = "stunnel";
|
2021-07-03 22:31:28 +00:00
|
|
|
version = "5.59";
|
2014-04-08 21:13:08 +00:00
|
|
|
|
2009-03-02 15:23:52 +00:00
|
|
|
src = fetchurl {
|
2019-08-15 12:41:18 +00:00
|
|
|
url = "https://www.stunnel.org/downloads/${pname}-${version}.tar.gz";
|
2021-07-03 22:31:28 +00:00
|
|
|
sha256 = "sha256-E3d232vo8XAfHNWQt3eZMuEjR5+5HlGSFxwWeYgVzp8=";
|
2018-02-01 00:00:00 +00:00
|
|
|
# please use the contents of "https://www.stunnel.org/downloads/${name}.tar.gz.sha256",
|
|
|
|
# not the output of `nix-prefetch-url`
|
2009-03-02 15:23:52 +00:00
|
|
|
};
|
|
|
|
|
2014-04-08 21:13:08 +00:00
|
|
|
buildInputs = [ openssl ];
|
2015-04-22 21:47:09 +00:00
|
|
|
configureFlags = [
|
2016-04-16 17:44:32 +00:00
|
|
|
"--with-ssl=${openssl.dev}"
|
2015-04-22 21:47:09 +00:00
|
|
|
"--sysconfdir=/etc"
|
|
|
|
"--localstatedir=/var"
|
|
|
|
];
|
|
|
|
|
2018-12-14 08:19:39 +00:00
|
|
|
postInstall = ''
|
|
|
|
# remove legacy compatibility-wrapper that would require perl
|
|
|
|
rm $out/bin/stunnel3
|
|
|
|
'';
|
|
|
|
|
2015-04-22 21:47:09 +00:00
|
|
|
installFlags = [
|
|
|
|
"sysconfdir=\${out}/etc"
|
|
|
|
"localstatedir=\${TMPDIR}"
|
|
|
|
];
|
2013-05-30 10:11:13 +00:00
|
|
|
|
2009-03-02 15:23:52 +00:00
|
|
|
meta = {
|
2016-06-20 10:53:46 +00:00
|
|
|
description = "Universal tls/ssl wrapper";
|
2020-01-22 10:26:22 +00:00
|
|
|
homepage = "https://www.stunnel.org/";
|
2021-01-15 09:19:50 +00:00
|
|
|
license = lib.licenses.gpl2Plus;
|
|
|
|
platforms = lib.platforms.unix;
|
|
|
|
maintainers = [ lib.maintainers.thoughtpolice ];
|
2009-03-02 15:23:52 +00:00
|
|
|
};
|
|
|
|
}
|