# -*- 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 108160 2013-07-15 03:06:59Z ryandesign@macports.org $

PortSystem      1.0
PortGroup       php5extension 1.0

php5extension.setup enchant 5.3.27 bundled
license         PHP
categories      php textproc devel
platforms       darwin
maintainers     ryandesign
description     libenchant binder, support near all spelling tools

long_description \
    Enchant is a binder for libenchant. Libenchant provides a common API for \
    many spell libraries.

checksums       rmd160  c2887004859f32b25229ffe52d86270c8de194b7 \
                sha256  e12db21c623b82a2244c4dd9b06bb75af20868c1b748a105a6829a5acc36b287

depends_lib-append \
    port:enchant

configure.args \
    --with-enchant=${prefix}

test.run yes

post-destroot {
    set docdir ${prefix}/share/doc/${name}
    xinstall -d ${destroot}${docdir}
    xinstall -m 644 -W ${destroot.dir} CREDITS ${destroot}${docdir}

    set examplesdir ${prefix}/share/examples/${name}
    xinstall -d ${destroot}${examplesdir}
    xinstall -m 644 ${destroot.dir}/docs/examples/example1.php \
        ${destroot}${examplesdir}
}
