# -*- 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

PortSystem          1.0
PortGroup           python 1.0
PortGroup           github 1.0

github.setup        python-openxml python-docx 0.8.9 v
name                py-docx
revision            0
categories-append   devel
platforms           darwin
license             MIT
maintainers         nomaintainer

description         Create and update Microsoft Word .docx files
long_description    ${description}

checksums           rmd160  23cfea337911d7cd5a664384c652ca022d789485 \
                    sha256  3eb8239cd12d50cbcb4728b3aa92b636cca54b0f2bfcb2a526bf6cefee5148b0 \
                    size    45185886

python.versions     27 37

if {${name} ne ${subport}} {
    depends_build-append \
                    port:py${python.version}-setuptools

    depends_lib-append \
                    port:py${python.version}-lxml

    depends_lib-append \
                    port:py${python.version}-mock \
                    port:py${python.version}-parsing \
                    port:py${python.version}-pytest
    test.run        yes
    test.cmd        py.test-${python.branch}
    test.target
    test.env        PYTHONPATH=${worksrcpath}/build/lib

    post-destroot {
        xinstall -m 0755 -d ${destroot}${prefix}/share/doc/${subport}
        xinstall -m 0644 -W ${worksrcpath} HISTORY.rst LICENSE README.rst \
            ${destroot}${prefix}/share/doc/${subport}
    }

    livecheck.type  none
}