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

name                py-prov
version             1.5.2
revision            0

categories-append   www devel
supported_archs     noarch
platforms           {darwin any}
license             MIT

maintainers         {petr @petrrr} openmaintainer

description         A Python library for W3C Provenance Data Model
long_description    {*}${description}. It supports PROV-JSON and PROV-XML \
                    serialization and deserialization, and exporting of \
                    PROV documents into various graphical formats, e.g. \
                    PDF, PNG, SVG.
homepage            https://prov.readthedocs.org

checksums           rmd160  903454cc85f899f315f9a850aaa399916dc26086 \
                    sha256  640dc158d931403bc6c1a0ad80702caae71f810bac21f90ec605865c8444b7bb \
                    size    137477

python.versions     310 311 312 313

if {${name} ne ${subport}} {
    depends_lib-append      port:py${python.version}-dateutil \
                            port:py${python.version}-lxml \
                            port:py${python.version}-networkx \
                            port:py${python.version}-rdflib \
                            port:py${python.version}-six

    # testing only
    depends_lib-append      port:py${python.version}-pydot

    # Adding documentation
    post-destroot {
        set dest_doc ${destroot}${prefix}/share/doc/${subport}
        xinstall -d  ${dest_doc}

        xinstall -m 0644 -W ${worksrcpath} \
            AUTHORS.rst \
            CHANGES.txt \
            CONTRIBUTING.rst \
            HISTORY.rst \
            LICENSE \
            README.rst \
                ${dest_doc}
    }
}
