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

name            gconf-editor
version         3.0.1
revision        1
license         GPL-2
set branch      [join [lrange [split ${version} .] 0 1] .]
description     An editor for the GConf configuration system.
long_description \
                ${description}
maintainers     nomaintainer
categories      gnome
platforms       darwin
homepage        https://www.gnome.org/projects/gconf/
master_sites    gnome:sources/gconf-editor/${branch}/

use_xz          yes

checksums       rmd160  75beeb6217ca8e6ea35049395261a7bb5b2f1a55 \
                sha256  3064e84967b4b4216f5c7e065cfec8c52019438a590e9ed81366af2770660944

depends_build   port:pkgconfig \
                port:intltool \
                port:gnome-doc-utils \
                port:gnome-common \
                port:autoconf \
                port:automake \
                port:libtool

depends_lib     port:desktop-file-utils \
                port:rarian \
                path:lib/pkgconfig/gtk+-3.0.pc:gtk3 \
                port:gconf
                

depends_run     port:gnome-settings-daemon

# reconfigure using upstream autogen.sh for intltool 0.51 compatibility

configure.cmd   ./autogen.sh

configure.args  --enable-compile-warnings=minimum \
                --disable-schemas-install \
                --disable-scrollkeeper

post-destroot {
    file delete -force ${destroot}${prefix}/var/scrollkeeper
}

post-activate {
    system "scrollkeeper-update"
    system "${prefix}/bin/gtk-update-icon-cache -f -t ${prefix}/share/icons/hicolor"
    system "${prefix}/bin/update-desktop-database ${prefix}/share/applications"
    system "export GCONF_CONFIG_SOURCE=`gconftool-2 --get-default-source` && \
        gconftool-2 --makefile-install-rule ${prefix}/etc/gconf/schemas/*.schemas"
}

livecheck.type  gnome
