# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
# $Id: Portfile 91611 2012-04-07 00:10:01Z ryandesign@macports.org $

PortSystem              1.0
PortGroup               php5extension 1.0

php5extension.setup     svn 1.0.2 pecl
categories-append       devel
platforms               darwin
maintainers             ryandesign

description             PHP bindings for Subversion

long_description        ${description}

checksums               rmd160  c4991e9a5c4203c0374529c4ddd156b6020af0a8 \
                        sha256  ca0ea834e745a1aae65b456800bb5c5cfd7c4eceff281f7a8e317d30726e48cd

depends_lib-append      port:subversion

patchfiles              patch-hook_emailcommit.php

post-patch {
    reinplace "s|@PREFIX@|${prefix}|g" ${worksrcpath}/examples/hook_emailcommit.php
}

configure.args-append   --with-svn=${prefix} \
                        --with-svn-apr=${prefix}/bin/apr-1-config

post-destroot {
    xinstall -d ${destroot}${prefix}/share/examples
    copy ${worksrcpath}/examples ${destroot}${prefix}/share/examples/${name}
}
