# -*- 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           muniversal 1.0

name                libsrtp
version             2.1.0
revision            1
categories          net devel
maintainers         {db.org:aeh @alfredh} openmaintainer
description         Secure Real-time Transport Protocol (SRTP)
long_description    The libSRTP library is an open-source implementation of \
                    the Secure Real-time Transport Protocol (SRTP).
homepage            https://github.com/cisco/libsrtp
platforms           darwin
master_sites        https://github.com/cisco/libsrtp/archive/
license             BSD

checksums           rmd160  436b1167489562ac7e3360136182ce4e28078ceb \
                    sha256  0302442ed97d34a77abf84617b657e77674bdd8e789d649f1cac0c5f0d0cf5ee

depends_build-append  port:pkgconfig
depends_lib-append                 \
    path:lib/libssl.dylib:openssl  \
    port:zlib                      \
    port:libpcap

configure.args-append \
    --enable-openssl

livecheck.url       https://github.com/cisco/libsrtp/releases
livecheck.regex     {/v(\d+(?:\.\d+)*)}

subport libsrtp1 {
    version             1.5.4
    revision            1

    checksums           rmd160  9a02b2644839147dd794d368cede6cf7f23d75e4 \
                        sha256  56a7b521c25134f48faff26b0b1e3d4378a14986a2d3d7bc6fefb48987304ff0

    livecheck.regex     {/v(1(?:\.\d+)*)}
}

distfiles           v${version}${extract.suffix}