# -*- 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           fortran 1.0
# PortGroup           cmake 1.1
# PortGroup           linear_algebra 1.0

github.setup        jacobwilliams bspline-fortran 7.4.0
name                fortran-bspline
revision            0
categories-append   math
license             BSD
maintainers         {@barracuda156 gmail.com:vital.had} openmaintainer
description         Multidimensional B-Spline interpolation of data on a regular grid
long_description    The library provides subroutines for 1D–6D interpolation \
                    and extrapolation using B-splines. The code is written in modern Fortran \
                    (i.e., Fortran 2003+). There are two ways to use the module, \
                    via a basic subroutine interface and an object-oriented interface. \
                    Both are thread-safe.
checksums           rmd160  e536bc0f70ae0a7b5c79ed09be8192aa8e85aff1 \
                    sha256  2c14d852c558388c8ba8a890d429c73be986d24ecce54dd4686e0e5579e49d31 \
                    size    439498
github.tarball_from archive

# Alternatively, build can be done via CMake and with external BLAS.
# See: https://github.com/jacobwilliams/bspline-fortran/blob/master/README.md
# build.cmd-append    --flag "-DHAS_BLAS -lblas"

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

test.run            yes