# -*- 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.20
    github.tarball_from archive
    revision            0

    checksums           rmd160  00477175c885b078e729d1ca90c01a1ae106ffdb \
                        sha256  84640ea0f43831850434e50134d0554b7a94f97fb02e2488ffbe252c9fb05a56 \
                        size    702527

    compiler.c_standard 2011

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