# $Id: Portfile 76493 2011-02-25 19:32:16Z blair@macports.org $

PortSystem          1.0
PortGroup           python25 1.0

name                py25-couchdb
version             0.8
categories          python www
platforms           darwin
maintainers         blair
homepage            http://code.google.com/p/couchdb-python/
description         Python library for working with CouchDB
long_description    Python library for working with CouchDB.  This package \
                    currently encompasses four primary modules: \
                    1) couchdb.client: the basic client library, \
                    2) couchdb.design: management of design documents, \
                    3) couchdb.schema: a higher-lever API for mapping between \
                       CouchDB documents and Python objects, \
                    4) couchdb.view: a CouchDB view server that allows \
                       writing view functions in Python 

master_sites        http://pypi.python.org/packages/source/C/CouchDB
distname            CouchDB-${version}
checksums           md5 e32b39e459e1fa2586ea252712a11a59 \
                    sha1 35004c40084097f03dc06a20556b84762e0214c7 \
                    rmd160 d67c310a07d558cdb7be6f12ad871c722f72dcbd

# Use py25-distribute as a library dependency instead of a build
# dependency because couchdb/__init__.py uses distribute's
# pkg_resources module.
depends_lib-append  port:py25-cjson \
                    port:py25-httplib2 \
                    port:py25-distribute

post-destroot {
    foreach f {couchdb-dump couchdb-load couchdb-replicate couchpy} {
        move ${destroot}${prefix}/bin/${f} ${destroot}${prefix}/bin/${f}-2.5
    }
}

livecheck.type      regex
livecheck.url       http://pypi.python.org/pypi/CouchDB
livecheck.regex     {CouchDB ([0-9]+\.[0-9]+(?:\.[0-9]+)?)}
