# -*- 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-ndindex
version             1.10.0
revision            0

maintainers         nomaintainer
license             MIT

description         Python library for manipulating indices of ndarrays
long_description    ndindex is a library that allows representing and \
                    manipulating objects that can be valid indices to \
                    numpy arrays, i.e., slices, integers, ellipses, \
                    None, integer and boolean arrays, and tuples \
                    thereof.

homepage            https://quansight-labs.github.io/ndindex/

checksums           rmd160  def1e5c4ad32ea5116df8b22b10c48f1fd3a3290 \
                    sha256  20e3a2f0a8ed4646abf0f13296aab0b5b9cc8c5bc182b71b5945e76eb6f558bb \
                    size    258688

python.versions     310 311 312 313

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

    build.env-append    "CYTHONIZE_NDINDEX=1"

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

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

    test.run        yes
    test.dir        ${destroot}${python.pkgd}
    test.env-append PYTHONPATH=${destroot}${python.pkgd}

    depends_test-append port:py${python.version}-hypothesis \
                        port:py${python.version}-sympy
}
