# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:filetype=tcl:et:sw=4:ts=4:sts=4
# $Id: Portfile 52345 2009-06-14 16:13:02Z jmr@macports.org $

PortSystem          1.0
PortGroup           python25 1.0

name                py25-pylibmc
version             0.6.1
maintainers         voldmar.ru:voldmar
description         python memcached client wrapped on libmemcached
long_description    pylibmc is a Python wrapper around the accompanying \
                    C Python extension _pylibmc, which is a wrapper around \
                    libmemcached from TangentOrg
platforms           darwin
homepage            http://pypi.python.org/pypi/pylibmc
master_sites        http://pypi.python.org/packages/source/p/pylibmc/
distname            pylibmc-${version}
checksums           md5 e1b82eb7dff446a034f174c93b6c9ac2 \
                    sha1 0743e6df37e22ab16b7f2f8d65508b8966bb77d6 \
                    rmd160 5b42103b01d086160159e97e0f9553627a6e13f1

depends_lib-append  port:libmemcached

patch {
    reinplace "s|/usr/local|${prefix}|g" ${worksrcpath}/setup.py
}

build.target        build_ext
build.args          --include-dirs=${prefix}/include:${prefix}/include/libmemcached \
                    --library-dirs=${prefix}/lib

post-destroot {
    xinstall -m 644 -W ${worksrcpath} \
         LICENSE benchmark.py tests.py \
         ${destroot}${prefix}/share/doc/${name}

}
