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

name                libdca
version             0.0.7
revision            1

categories          audio
license             GPL-2+
maintainers         nomaintainer

description         libdca is a free library for decoding DTS Coherent \
                    Acoustics streams.
long_description    ${description}
homepage            https://www.videolan.org/developers/libdca.html

master_sites        https://download.videolan.org/pub/videolan/libdca/${version}/
use_bzip2           yes

checksums           rmd160  24a7ae60b93efaedeee7e2e0aa318ca6afcaaf39 \
                    sha256  3a0b13815f582c661d2388ffcabc2f1ea82f471783c400f765f2ec6c81065f6a \
                    size    158232

# Upstream patch for broken symlink libdts.a
# Source: https://code.videolan.org/videolan/libdca/-/issues/3#note_56339
patchfiles-append   patch-libdts.a-symlink-fix.diff

# v. 0.0.7 tarball does not include pre-processed configure script.
use_autoreconf      yes

configure.cflags-append \
                     -std=gnu89

configure.args-append \
                    --disable-silent-rules

livecheck.type      regex
livecheck.regex     {Current release is <a.*>libdca-(.*).tar.bz2</a>}
livecheck.url       ${homepage}
