pgpool: 4.0.6 -> 4.3.2

Among other things fixes build against -fno-common toolchains.

Changes: https://www.pgpool.net/docs/latest/en/html/release-4-3-2.html
This commit is contained in:
Sergei Trofimovich 2022-05-28 19:45:37 +01:00
parent 0831857a14
commit 2dfcfcc1a9
2 changed files with 2 additions and 27 deletions

View File

@ -2,16 +2,14 @@
stdenv.mkDerivation rec {
pname = "pgpool-II";
version = "4.0.6";
version = "4.3.2";
src = fetchurl {
name = "${pname}-${version}.tar.gz";
url = "http://www.pgpool.net/download.php?f=${pname}-${version}.tar.gz";
sha256 = "0blmbqczyrgzykby2z3xzmhzd8kgij9izxv50n5cjn5azf7dn8g5";
sha256 = "02jg0c6k259i0r927dng9h0y58q965swshg2c9mzqhazcdiga5ap";
};
patches = [ ./pgpool.patch ];
buildInputs = [ postgresql openssl pam libmemcached ];
configureFlags = [

View File

@ -1,23 +0,0 @@
diff --git a/src/main/main.c b/src/main/main.c
index eec3c3e4..4169112b 100644
--- a/src/main/main.c
+++ b/src/main/main.c
@@ -337,10 +337,14 @@ main(int argc, char **argv)
char dirnamebuf[POOLMAXPATHLEN + 1];
char *dirp;
- strlcpy(dirnamebuf, conf_file, sizeof(dirnamebuf));
- dirp = dirname(dirnamebuf);
- snprintf(pool_passwd, sizeof(pool_passwd), "%s/%s",
- dirp, pool_config->pool_passwd);
+ if (pool_config->pool_passwd[0] != '/') {
+ strlcpy(dirnamebuf, conf_file, sizeof(dirnamebuf));
+ dirp = dirname(dirnamebuf);
+ snprintf(pool_passwd, sizeof(pool_passwd), "%s/%s",
+ dirp, pool_config->pool_passwd);
+ } else
+ strlcpy(pool_passwd, pool_config->pool_passwd,
+ sizeof(pool_passwd));
pool_init_pool_passwd(pool_passwd, POOL_PASSWD_R);
}