summaryrefslogtreecommitdiff
path: root/databases/pgbouncer
diff options
context:
space:
mode:
authorfhajny <fhajny>2015-10-23 16:40:38 +0000
committerfhajny <fhajny>2015-10-23 16:40:38 +0000
commit460a682529bbe39592a019add92ffe944fa72318 (patch)
treedfc2718af036e2d7bbad1abccfdfe3921a288873 /databases/pgbouncer
parent49dfd8b9c84d3062f3a8e74ea8b770a8a6c6ce13 (diff)
downloadpkgsrc-460a682529bbe39592a019add92ffe944fa72318.tar.gz
Uddate databases/pgbouncer to 1.6.1.
Update home page & master site, clean up. PgBouncer 1.6.1. - Security fix for CVE-2015-6817. - Per-pool pooling mode vs. reset query. Details: http://pgbouncer.github.io/2015/09/pgbouncer-1-6-1/ PgBouncer 1.6.0 Main new features: - Load user password hash from postgres database. - Pooling mode can be configured both per-database and per-user. - Per-database and per-user connection limits: max_db_connections and max_user_connections. - Add DISABLE/ENABLE commands to prevent new connections. - New preferred DNS backend: c-ares. - Config files have %include FILENAME directive to allow configuration to be split into several files. Details: http://pgbouncer.github.io/2015/08/pgbouncer-1-6/ PgBouncer 1.5.5 - Fix remote crash - invalid packet order causes lookup of NULL pointer. Not exploitable, just DoS.
Diffstat (limited to 'databases/pgbouncer')
-rw-r--r--databases/pgbouncer/Makefile47
-rw-r--r--databases/pgbouncer/PLIST6
-rw-r--r--databases/pgbouncer/distinfo11
-rw-r--r--databases/pgbouncer/patches/patch-Makefile16
-rw-r--r--databases/pgbouncer/patches/patch-lib_usual_endian_h24
5 files changed, 50 insertions, 54 deletions
diff --git a/databases/pgbouncer/Makefile b/databases/pgbouncer/Makefile
index 2a665ddf67b..1774ddab056 100644
--- a/databases/pgbouncer/Makefile
+++ b/databases/pgbouncer/Makefile
@@ -1,31 +1,19 @@
-# $NetBSD: Makefile,v 1.8 2014/05/13 14:18:49 fhajny Exp $
+# $NetBSD: Makefile,v 1.9 2015/10/23 16:40:38 fhajny Exp $
#
-DISTNAME= pgbouncer-${VERSION}
+DISTNAME= pgbouncer-1.6.1
CATEGORIES= databases
-MASTER_SITES= http://pgfoundry.org/frs/download.php/3393/
-EXTRACT_SUFX= .tgz
+MASTER_SITES= http://pgbouncer.github.io/downloads/files/${PKGVERSION_NOREV}/
MAINTAINER= pkgsrc@NetBSD.org
-HOMEPAGE= http://wiki.postgresql.org/wiki/PgBouncer
+HOMEPAGE= http://pgbouncer.github.io/
COMMENT= Lightweight connection pooler for PostgreSQL
LICENSE= original-bsd
-VERSION= 1.5.4
USE_LANGUAGES= c
USE_TOOLS+= gmake
GNU_CONFIGURE= yes
-CONFIGURE_ARGS+= --with-libevent=${BUILDLINK_PREFIX.libevent}
-
-EGDIR= ${PREFIX}/share/examples/${PKGBASE}
-CONF_FILES= ${EGDIR}/pgbouncer.ini ${PKG_SYSCONFDIR}/pgbouncer.ini \
- ${EGDIR}/pgbouncer.userlist ${PKG_SYSCONFDIR}/pgbouncer.userlist
-
-RCD_SCRIPTS+= pgbouncer
-
-INSTALLATION_DIRS= bin ${PKGMANDIR}/man1 ${PKGMANDIR}/man5 ${EGDIR}
-
.include "../../mk/bsd.prefs.mk"
PGUSER?= pgsql
@@ -45,6 +33,12 @@ PGB_RUN_DIR?= ${VARBASE}/run
OWN_DIRS_PERMS+= ${PGB_LOG_DIR} ${PGUSER} ${PGGROUP} 0755
+EGDIR= ${PREFIX}/share/examples/${PKGBASE}
+CONF_FILES= ${EGDIR}/pgbouncer.ini ${PKG_SYSCONFDIR}/pgbouncer.ini \
+ ${EGDIR}/userlist.txt ${PKG_SYSCONFDIR}/pgbouncer.userlist
+
+RCD_SCRIPTS+= pgbouncer
+
SUBST_CLASSES+= path
SUBST_STAGE.path= pre-configure
SUBST_MESSAGE.path= Fixing default paths
@@ -52,15 +46,22 @@ SUBST_FILES.path= etc/pgbouncer.ini
SUBST_SED.path= -e 's|/var/log/pgbouncer|${PGB_LOG_DIR}|g'
SUBST_SED.path+= -e 's|/var/run/pgbouncer|${PGB_RUN_DIR}|g'
SUBST_SED.path+= -e 's|/etc/pgbouncer|${PKG_SYSCONFDIR}|g'
+SUBST_SED.path+= -e 's|userlist.txt|pgbouncer.userlist|g'
+
+CONFIGURE_ARGS+= --with-cares=${BUILDLINK_PREFIX.libcares}
+CONFIGURE_ARGS+= --with-libevent=${BUILDLINK_PREFIX.libevent}
+
+CPPFLAGS.SunOS+= -D_STRUCTURED_PROC=1
-do-install:
- ${INSTALL_PROGRAM} ${WRKSRC}/pgbouncer ${DESTDIR}${PREFIX}/bin/
- ${INSTALL_MAN} ${WRKSRC}/doc/pgbouncer.1 ${DESTDIR}${PREFIX}/${PKGMANDIR}/man1/
- ${INSTALL_MAN} ${WRKSRC}/doc/pgbouncer.5 ${DESTDIR}${PREFIX}/${PKGMANDIR}/man5/
- ${INSTALL_DATA} ${WRKSRC}/etc/pgbouncer.ini ${DESTDIR}${EGDIR}
- ${INSTALL_DATA} ${WRKSRC}/etc/userlist.txt ${DESTDIR}${EGDIR}/pgbouncer.userlist
+# Avoid unwanted asciidoc/xmlto matches, get on without the html doc files.
+# Bundled install-sh script unreliable. Install sample config files.
+INSTALL_MAKE_FLAGS+= ASCIIDOC=
+INSTALL_MAKE_FLAGS+= MKDIR_P=${INSTALL_DATA_DIR:Q}
+INSTALL_MAKE_FLAGS+= sysconfdir=${EGDIR}
+
+INSTALLATION_DIRS= bin ${PKGMANDIR}/man1 ${PKGMANDIR}/man5 ${EGDIR}
BUILDLINK_API_DEPENDS.libevent+= libevent>=2.0
.include "../../devel/libevent/buildlink3.mk"
-
+.include "../../net/libcares/buildlink3.mk"
.include "../../mk/bsd.pkg.mk"
diff --git a/databases/pgbouncer/PLIST b/databases/pgbouncer/PLIST
index ead929d8e3c..2c171585de4 100644
--- a/databases/pgbouncer/PLIST
+++ b/databases/pgbouncer/PLIST
@@ -1,6 +1,8 @@
-@comment $NetBSD: PLIST,v 1.2 2014/03/11 14:05:00 jperkin Exp $
+@comment $NetBSD: PLIST,v 1.3 2015/10/23 16:40:38 fhajny Exp $
bin/pgbouncer
man/man1/pgbouncer.1
man/man5/pgbouncer.5
+share/doc/pgbouncer/NEWS
+share/doc/pgbouncer/README
share/examples/pgbouncer/pgbouncer.ini
-share/examples/pgbouncer/pgbouncer.userlist
+share/examples/pgbouncer/userlist.txt
diff --git a/databases/pgbouncer/distinfo b/databases/pgbouncer/distinfo
index 6af3249fcbb..4ecc3e33f57 100644
--- a/databases/pgbouncer/distinfo
+++ b/databases/pgbouncer/distinfo
@@ -1,6 +1,7 @@
-$NetBSD: distinfo,v 1.3 2014/05/13 14:18:49 fhajny Exp $
+$NetBSD: distinfo,v 1.4 2015/10/23 16:40:38 fhajny Exp $
-SHA1 (pgbouncer-1.5.4.tgz) = 87c3dd7fc70cbbae93ce8865953891f0aabffd2d
-RMD160 (pgbouncer-1.5.4.tgz) = bb7e48ab7ed723b2e35999af9dbc63acf02f65f9
-Size (pgbouncer-1.5.4.tgz) = 339610 bytes
-SHA1 (patch-lib_usual_endian_h) = 65629eb5f2fda9b1c6fb2a2628bea3df737522ac
+SHA1 (pgbouncer-1.6.1.tar.gz) = 4abeee4965a26197e2c193d6bfb01eef46aa72a8
+RMD160 (pgbouncer-1.6.1.tar.gz) = 3eb6d6aae0f634c71bf28eae5f5aa471c4016a9d
+SHA512 (pgbouncer-1.6.1.tar.gz) = cf1cd28b04531bce879f3f9f50b54754253e0d9882c7f122c99d1c0c39fb01264c1ba20f5fd7b42ce7f5356f413b05caf48bbb633693d866271e129426923529
+Size (pgbouncer-1.6.1.tar.gz) = 431076 bytes
+SHA1 (patch-Makefile) = 9c33efeb8c3c70487cdca056002928fc955a8307
diff --git a/databases/pgbouncer/patches/patch-Makefile b/databases/pgbouncer/patches/patch-Makefile
new file mode 100644
index 00000000000..a27281b26f2
--- /dev/null
+++ b/databases/pgbouncer/patches/patch-Makefile
@@ -0,0 +1,16 @@
+$NetBSD: patch-Makefile,v 1.1 2015/10/23 16:40:38 fhajny Exp $
+
+Install sample config files as... config files.
+
+--- Makefile.orig 2015-09-03 14:46:31.000000000 +0000
++++ Makefile
+@@ -47,7 +47,8 @@ AM_FEATURES = libusual
+ pgbouncer_EMBED_LIBUSUAL = 1
+
+ # docs to install as-is
+-dist_doc_DATA = README NEWS etc/pgbouncer.ini etc/userlist.txt
++dist_doc_DATA = README NEWS
++dist_sysconf_DATA = etc/pgbouncer.ini etc/userlist.txt
+
+ DISTCLEANFILES = config.mak config.status lib/usual/config.h config.log
+
diff --git a/databases/pgbouncer/patches/patch-lib_usual_endian_h b/databases/pgbouncer/patches/patch-lib_usual_endian_h
deleted file mode 100644
index 1afdfb40895..00000000000
--- a/databases/pgbouncer/patches/patch-lib_usual_endian_h
+++ /dev/null
@@ -1,24 +0,0 @@
-$NetBSD: patch-lib_usual_endian_h,v 1.2 2014/05/13 14:18:50 fhajny Exp $
-
-Avoid trying to redefine bswap16/32/64 when on NetBSD.
-
---- lib/usual/endian.h.orig 2011-11-29 15:40:56.000000000 +0000
-+++ lib/usual/endian.h
-@@ -42,6 +42,8 @@
- * @{
- */
-
-+#ifndef __NetBSD__ /* already in sys/endian.h */
-+
- #ifndef bswap16
- #ifdef bswap_16
- #define bswap16(x) bswap_16(x)
-@@ -80,6 +82,8 @@ static inline uint64_t bswap64(uint64_t
- #endif
- #endif
-
-+#endif /* NetBSD */
-+
- /* @} */
-
- /**