summaryrefslogtreecommitdiff
path: root/databases/pgbouncer/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'databases/pgbouncer/Makefile')
-rw-r--r--databases/pgbouncer/Makefile26
1 files changed, 21 insertions, 5 deletions
diff --git a/databases/pgbouncer/Makefile b/databases/pgbouncer/Makefile
index f0c8d8ad4f9..2a665ddf67b 100644
--- a/databases/pgbouncer/Makefile
+++ b/databases/pgbouncer/Makefile
@@ -1,10 +1,9 @@
-# $NetBSD: Makefile,v 1.7 2014/02/12 23:17:40 tron Exp $
+# $NetBSD: Makefile,v 1.8 2014/05/13 14:18:49 fhajny Exp $
#
DISTNAME= pgbouncer-${VERSION}
-PKGREVISION= 3
CATEGORIES= databases
-MASTER_SITES= http://pgfoundry.org/frs/download.php/3085/
+MASTER_SITES= http://pgfoundry.org/frs/download.php/3393/
EXTRACT_SUFX= .tgz
MAINTAINER= pkgsrc@NetBSD.org
@@ -12,7 +11,7 @@ HOMEPAGE= http://wiki.postgresql.org/wiki/PgBouncer
COMMENT= Lightweight connection pooler for PostgreSQL
LICENSE= original-bsd
-VERSION= 1.4.2
+VERSION= 1.5.4
USE_LANGUAGES= c
USE_TOOLS+= gmake
GNU_CONFIGURE= yes
@@ -33,9 +32,26 @@ PGUSER?= pgsql
PGGROUP?= pgsql
PKG_GROUPS= ${PGGROUP}
PKG_USERS= ${PGUSER}:${PGGROUP}
+PKG_GECOS.${PGUSER}= PostgreSQL database administrator
+PKG_HOME.${PGUSER}= ${PGHOME}
-BUILD_DEFS+= PGUSER PGGROUP
+BUILD_DEFS+= PGUSER PGGROUP PGHOME VARBASE
FILES_SUBST+= PGUSER=${PGUSER}
+FILES_SUBST+= PGGROUP=${PGGROUP}
+FILES_SUBST+= PGHOME=${PGHOME}
+
+PGB_LOG_DIR?= ${VARBASE}/log/pgbouncer
+PGB_RUN_DIR?= ${VARBASE}/run
+
+OWN_DIRS_PERMS+= ${PGB_LOG_DIR} ${PGUSER} ${PGGROUP} 0755
+
+SUBST_CLASSES+= path
+SUBST_STAGE.path= pre-configure
+SUBST_MESSAGE.path= Fixing default paths
+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'
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/pgbouncer ${DESTDIR}${PREFIX}/bin/