# -*- 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-iminuit
version             2.31.1
revision            0

categories-append   science
license             LGPL
maintainers         nomaintainer

description         MINUIT from Python - Fitting like a boss
long_description    {*}${description}

homepage            https://iminuit.readthedocs.io/en/latest/

checksums           rmd160  3a580a2ca726878387b8cff090715d970c40bcda \
                    sha256  d5e004f1ffd83d2a076409fbf4a79691e7a17c9d73950bb63465af32e104de18 \
                    size    1840604

python.versions     310 311 312

compiler.cxx_standard   2014
compiler.thread_local_storage yes

if {${name} ne ${subport}} {
    depends_build-append \
                    port:py${python.version}-scikit-build-core \
                    port:py${python.version}-pybind11 \
                    port:py${python.version}-pathspec \
                    port:py${python.version}-pyproject_metadata \
                    port:ninja \
                    path:bin/cmake:cmake

    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} LICENSE README.rst \
            ${destroot}${docdir}
    }
}
