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

name                juk
version             4.14.3
revision            3
categories          kde kde4
maintainers         nomaintainer
license             GPL-2+
description         JuK is an audio jukebox application
long_description    JuK is an audio jukebox application, supporting collections \
                    of MP3, Ogg Vorbis, and FLAC audio files. It allows you to edit \
                    the "tags" of your audio files, and manage your collection and \
                    playlists. It's main focus, in fact, is on music management.
homepage            https://www.kde.org
platforms           darwin
master_sites        kde:stable/${version}/src/
use_xz              yes
checksums           rmd160  7988b5884b7e98f1c1ab1aeabd734d0d0b6a1559 \
                    sha256  03f517c9b389ebd8a0bd153c5c0400682c34089ce102e92e4f4cad46c606bb09

#Binaries do not link to openssl, nor use the ssl backend of kdelibs4
license_noconflict  openssl

depends_lib-append  port:kdelibs4 \
                    port:taglib

if {![variant_isset docs]} {
    patchfiles-append   patch-CMakeLists.txt.diff
}

pre-configure {
    #Ensure that we find taglib
    reinplace "s|\${TAGLIB_INCLUDES}|${prefix}/include/taglib|g" \
        ${worksrcpath}/CMakeLists.txt
    reinplace "s|\${TAGLIB_LIBRARIES}|${prefix}/lib/libtag.dylib|g" \
        ${worksrcpath}/CMakeLists.txt
}

livecheck.url       ${kde4.mirror}
livecheck.regex     (\\d+(\\.\\d+)+)
