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

name                zenity
# latest version that supports current webkit2-gtk API 4.0
version             3.42.1
revision            0
set branch          [join [lrange [split ${version} .] 0 1] .]
description         Zenity allows you to display dialog boxes from the commandline.
long_description    {*}{description}
maintainers         {devans @dbevans} openmaintainer
categories          gnome
license             LGPL-2+
homepage            https://wiki.gnome.org/Projects/Zenity
master_sites        gnome:sources/${name}/${branch}/

use_xz              yes

checksums           rmd160  057f9725a4186a57954419f14503e146d7914a0e \
                    sha256  a08e0c8e626615ee2c23ff74628eba6f8b486875dd54371ca7e2d7605b72a87c \
                    size    3091752

depends_build       port:gettext \
                    port:itstool \
                    path:bin/pkg-config:pkgconfig

depends_lib         path:lib/pkgconfig/gtk+-3.0.pc:gtk3 \
                    port:gettext-runtime \
                    port:libiconv \
                    port:xorg-libX11

depends_run         port:adwaita-icon-theme

variant libnotify description "Enable libnotify for desktop notification support" {
    depends_lib-append \
                    port:libnotify

    configure.args-append \
                    -Dlibnotify=true
}

variant webkitgtk description "Enable WebKitGTK 4.0 support" {
    depends_lib-append \
                    path:lib/pkgconfig/webkit2gtk-4.0.pc:webkit2-gtk

    configure.args-append \
                    -Dwebkitgtk=true
}

default_variants +libnotify +webkitgtk

livecheck.type      gnome
