# -*- 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.25.2
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  630793607aaaac7403b216af7af86f507f1724e8 \
                    sha256  3bf8a1b96865a60cedf29135f4feae09fa7c66237d29f68ded64e97a823a9b3e \
                    size    2929388

python.versions     39 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}
    }
}
