# -*- 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
# $Id: Portfile 107849 2013-07-07 07:28:07Z nicos@macports.org $

PortSystem          1.0
PortGroup           kde4   1.1

name                gwenview
version             4.10.5
categories          kde kde4
license             GPL-2+
maintainers         nicos openmaintainer
description         Gwenview is an image viewer for KDE.
long_description    Gwenview can load and save all image formats supported by KDE.
platforms           darwin
homepage            http://www.kde.org/applications/graphics/gwenview/
master_sites        kde:stable/${version}/src/
use_xz              yes
distname            gwenview-${version}
checksums           rmd160  a9bac959d3898b80149e7b8b0a550ca66c5ccead \
                    sha256  1bc35f092c4009a28d5e0504b23411c1e19013294375c836ee7854d986dae367

#Binaries do not link directly to openssl, nor use the ssl backend of kdelibs4,
#nor links to libkimap or libmailtransport from kdepimlibs4
license_noconflict  openssl

depends_lib-append  port:kdelibs4 \
                    port:kde4-baseapps \
                    port:exiv2 \
                    port:libkipi \
                    port:jpeg \
                    port:libpng \
                    port:lcms2

#Temporary patch to allow using the newer jpeg with gwenview 4.9.5 & 4.10.1
patchfiles-append   patch-CMakeLists-lib.txt.diff

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

configure.args-append   -DGWENVIEW_SEMANTICINFO_BACKEND=None

variant kipi description "adds support for KDE Image Plugin Interface" { 
 depends_lib-append port:kipi-plugins
}

livecheck.url       http://kde.mirrors.hoobly.com/stable/
livecheck.regex     (\\d+(\\.\\d+)+)
