# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:filetype=tcl:et:sw=4:ts=4:sts=4
# $Id: Portfile 117417 2014-02-25 22:12:00Z devans@macports.org $

PortSystem      1.0

name            libsecret
version         0.16
set branch      [join [lrange [split ${version} .] 0 1] .]
maintainers     jeremyhu openmaintainer
categories      gnome
platforms       darwin
license         LGPL-2.1
description     libsecret is a library for storing and retrieving passwords and other secrets

long_description \
    libsecrets is a client for the Secret Service DBus API. The Secret \
    Service allows storage of passwords in a common way on the desktop. \
    Supported by gnome-keyring and ksecretservice.

homepage        https://wiki.gnome.org/Projects/Libsecret
master_sites    gnome:sources/${name}/${branch}/
use_xz          yes

checksums       rmd160  f63400bf2d8209675d28b26c137fb073ca91e37e \
                sha256  b859406c490a2011b35f5940235304315b343f2efd554800285f24b95e14f218

depends_build   port:intltool \
                port:pkgconfig \
                port:libxslt \
                port:gtk-doc

depends_lib     path:lib/pkgconfig/glib-2.0.pc:glib2 \
                port:gobject-introspection \
                port:vala \
                port:libgcrypt

# update build/m4/intltool.m4 and autoreconf

pre-configure {
    copy -force ${prefix}/share/aclocal/intltool.m4 ${worksrcpath}/build/m4
}

use_autoreconf  yes
autoreconf.args -fvi

configure.args  --disable-silent-rules

platform darwin 8 {
    # The rules enabled by gobject-introspection require GNU make 3.81+
    depends_build-append    port:gmake
    build.cmd               ${prefix}/bin/gmake
}

livecheck.type  gnome
