# -*- 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           github 1.0
PortGroup           legacysupport 1.1
PortGroup           openssl 1.0

name                iperf3
categories          net
license             BSD
maintainers         {gmail.com:allan.que @aque} openmaintainer
description         Measures the maximum achievable bandwidth on IP networks
long_description    ${name} is a tool for active measurements of the maximum \
                    achievable bandwidth on IP networks. It supports tuning \
                    of various parameters related to timing, protocols, and \
                    buffers. For each test it reports the bandwidth, loss, \
                    and other parameters.

test.run            yes
test.target         check

post-destroot {
    # install doc files
    xinstall -d ${destroot}${prefix}/share/doc/${name}
    xinstall -m 644 -W ${worksrcpath} LICENSE RELNOTES.md README.md \
        ${destroot}${prefix}/share/doc/${name}
}

# getline, strndup
legacysupport.newest_darwin_requires_legacy \
                    10

if {${subport} eq ${name}} {
    github.setup        esnet iperf 3.19.1
    github.tarball_from archive
    revision            0

    checksums           rmd160  aa17f75dd65ad839c97e9b8ee6145dce55b7d8ab \
                        sha256  85e480d7fffdcb1368888aaee9d76bcfc211e17c2a6dcb2060b281498f82c97b \
                        size    698445

    compiler.c_standard 2011

    github.livecheck.regex {([0-9.]+)}
}
