# -*- 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 92327 2012-04-25 07:20:33Z ryandesign@macports.org $

PortSystem                  1.0
PortGroup                   php5extension 1.0

# Keep relevant lines in sync between ming and php5-ming.

php5extension.setup         ming 0.4.4
categories-append           multimedia graphics
platforms                   darwin
maintainers                 ryandesign
license                     PHP-3.01
homepage                    http://www.libming.org/
master_sites                sourceforge:project/ming/Releases
dist_subdir                 ming
use_bzip2                   yes
worksrcdir                  ${worksrcdir}/php_ext
extract.post_args-append    ${worksrcdir}

description                 a PHP interface for generating Flash SWF files with Ming

long_description            ${description}

checksums                   rmd160  2070cd694b9a1ff8dd0a577df2f551d5d810e4fe \
                            sha256  40e09d781741ac961338ed8dec7ba2ed06217de9da44dd67af6b881b95d2af7e

depends_lib-append          port:ming

post-extract {
    # config.m4 is missing from the 0.4.4 distfile; see:
    # https://github.com/libming/libming/issues/8
    copy ${filespath}/config.m4 ${worksrcpath}
}

patchfiles-append           patch-config.m4.diff

configure.args-append       --with-ming=${prefix}

livecheck.regex             /ming-(\[0-9.\]+)${extract.suffix}
