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

github.setup        bernhardu dvbcut-deb 0.7.3 v
github.tarball_from archive
revision            0

name                dvbcut
categories          multimedia
platforms           darwin
license             GPL-2
maintainers         nomaintainer
description         Qt application for cutting parts out of DVB streams
long_description    DVBcut is a Qt application that allows you to select certain parts of an \
                    MPEG transport stream and save these parts into a single MPEG output file. \
                    It follows a keyhole surgery approach where the input video and audio data \
                    is mostly kept unchanged, and only very few frames at the beginning and/or \
                    end of the selected range are re-encoded in order to obtain a valid MPEG \
                    file.

checksums           rmd160  7ae24ba9c72754effc92a88a694a092ad416e2f9 \
                    sha256  c0397919e89bd3a77f488b8c25d3bad9a11f14cd30d16097c3bf666bc3f56d7b \
                    size    186547

patchfiles          pkgconfig.patch byteswap.patch

depends_lib         port:a52dec \
                    path:lib/libavcodec.dylib:ffmpeg \
                    port:libao \
                    port:libmad
depends_build       port:pkgconfig
qt5.depends_build_component qttools

use_autoreconf      yes

compiler.cxx_standard 2011
configure.cxxflags-append -std=c++11

configure.env       PATH=$env(PATH):${prefix}/libexec/qt5/bin
build.env           PATH=$env(PATH):${prefix}/libexec/qt5/bin

post-destroot {
    file mkdir "${destroot}${prefix}/share/dvbcut/icons"
    file copy "${worksrcpath}/dvbcut.svg" "${destroot}${prefix}/share/dvbcut/icons/dvbcut.svg"
}
