# $Id: Portfile 67791 2010-05-18 15:05:33Z giorgio_v@macports.org $

PortSystem 1.0

name			pgbouncer
version			1.3.3
categories		databases
platforms		darwin
maintainers		mac.com:giorgio_v
description		Lightweight connection pooler for PostgreSQL
long_description	pgbouncer is a PostgreSQL connection pooler. \
			Any target application can be connected to \
			pgbouncer as if it were a PostgreSQL server, \
			and pgbouncer will manage to connect to the \
			server, or to reuse one of its existing	connections.

homepage		http://pgbouncer.projects.postgresql.org/
master_sites		http://pgfoundry.org/frs/download.php/2677/
checksums		md5 2ebd1d907db8518cb9e34534372012ac \
			sha1 248f4e498c0129541277b6c1dac52ccaaa1eeb52 \
			rmd160 8ff192dd4bb0df7895858026c8cf47f375db8e6b

configure.env		PATH=$env(PATH):${prefix}/lib/postgresql84/bin

depends_build		port:postgresql84
depends_lib             port:libevent

livecheck.type	regex
livecheck.url	http://pgfoundry.org/frs/?group_id=1000258
livecheck.regex	pgbouncer-(\[0-9\\.\]+)\\.tgz

variant postgresql82 description {uses postgresql82 installation} {
	depends_build		port:postgresql82
	configure.env		PATH=$env(PATH):${prefix}/lib/postgresql82/bin
}

variant postgresql83 description {uses postgresql83 installation} {
	depends_build		port:postgresql83
	configure.env		PATH=$env(PATH):${prefix}/lib/postgresql83/bin
}
