# -*- 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        Unidata cftime 1.6.5 v rel
github.tarball_from archive
name                py-cftime
revision            0

categories-append   devel
license             MIT
maintainers         {reneeotten @reneeotten} openmaintainer

description         Time-handling functionality from netcdf4-python
long_description    {*}${description}

checksums           rmd160  42ff4f7eeb9f9095056623426b9acbf3b216d0e7 \
                    sha256  42c383aea81c121e82c1b2e651e42ad125b09bffcbcbc263ba3a7617260a907c \
                    size    61804

python.versions     310 311 312 313 314

if {${name} ne ${subport}} {
    depends_build-append \
                    port:py${python.version}-cython \
                    port:py${python.version}-oldest-supported-numpy

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

    test.run        yes

    post-destroot {
        set docdir ${prefix}/share/doc/${subport}
        xinstall -d ${destroot}${docdir}
        xinstall -m 0644 -W ${worksrcpath} README.md Changelog \
            LICENSE ${destroot}${docdir}
    }
}
