2021-01-11 07:54:33 +00:00
|
|
|
{ lib, stdenv, fetchurl, postgresql, openssl, pam ? null, libmemcached ? null }:
|
2014-11-15 09:23:07 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-08-07 12:15:10 +01:00
|
|
|
pname = "pgpool-II";
|
2019-08-20 11:56:19 +01:00
|
|
|
version = "4.0.6";
|
2014-11-15 09:23:07 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
2019-08-15 13:41:18 +01:00
|
|
|
name = "${pname}-${version}.tar.gz";
|
|
|
|
url = "http://www.pgpool.net/download.php?f=${pname}-${version}.tar.gz";
|
2019-08-20 11:56:19 +01:00
|
|
|
sha256 = "0blmbqczyrgzykby2z3xzmhzd8kgij9izxv50n5cjn5azf7dn8g5";
|
2014-11-15 09:23:07 +00:00
|
|
|
};
|
|
|
|
|
2019-08-07 12:15:10 +01:00
|
|
|
patches = [ ./pgpool.patch ];
|
2017-11-16 02:17:45 +00:00
|
|
|
|
2015-04-08 20:10:31 +01:00
|
|
|
buildInputs = [ postgresql openssl pam libmemcached ];
|
|
|
|
|
|
|
|
configureFlags = [
|
|
|
|
"--sysconfdir=/etc"
|
|
|
|
"--localstatedir=/var"
|
|
|
|
"--with-openssl"
|
2021-01-15 07:07:56 +00:00
|
|
|
] ++ lib.optional (pam != null) "--with-pam"
|
|
|
|
++ lib.optional (libmemcached != null) "--with-memcached=${libmemcached}";
|
2015-04-08 20:10:31 +01:00
|
|
|
|
|
|
|
installFlags = [
|
|
|
|
"sysconfdir=\${out}/etc"
|
|
|
|
];
|
2014-11-15 09:23:07 +00:00
|
|
|
|
2017-11-16 02:17:45 +00:00
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "http://pgpool.net/mediawiki/index.php";
|
2015-04-28 09:54:58 +01:00
|
|
|
description = "A middleware that works between postgresql servers and postgresql clients";
|
2014-11-15 09:23:07 +00:00
|
|
|
license = licenses.free;
|
2015-04-05 03:43:54 +01:00
|
|
|
platforms = platforms.linux;
|
2014-11-15 09:23:07 +00:00
|
|
|
};
|
|
|
|
}
|