# -*- 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$

PortSystem          1.0
PortGroup           gobject_introspection 1.0

name                zeitgeist
version             0.9.16
license             LGPL-2.1
set branch          [join [lrange [split ${version} .] 0 1] .]
description         Zeitgeist is a service which logs the users's activities and \
                    events (files opened, websites visites, conversations held with \
                    other people, etc.) and makes relevant information available to \
                    other applications.
long_description    ${description}
maintainers         devans openmaintainer
categories          devel
platforms           darwin
homepage            http://cgit.freedesktop.org/zeitgeist/zeitgeist
master_sites        http://cgit.freedesktop.org/zeitgeist/zeitgeist/snapshot/

checksums           rmd160  487c99d01cb90ffd0f61c2d502183d3c5fe2aa77 \
                    sha256  e43b25dbcddf11dff8e61c3946391ce242dc84ca2c64a019bdb06ab1edf64c13

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

depends_lib         port:gtk3 \
                    path:lib/pkgconfig/glib-2.0.pc:glib2 \
                    port:dbus \
                    port:json-glib \
                    port:telepathy-glib \
                    port:py27-rdflib \
                    port:raptor2 \
                    port:vala

gobject_introspection yes

configure.python    ${prefix}/bin/python2.7

patchfiles          patch-configure.ac.diff

post-patch {
    reinplace "s|^#\!.*|#!${configure.python}|" \
        ${worksrcpath}/data/ontology2code \
        ${worksrcpath}/test/dbus/blacklist-test.py \
        ${worksrcpath}/test/dbus/dsr-test.py \
        ${worksrcpath}/test/dbus/engine-test.py \
        ${worksrcpath}/test/dbus/histogram-test.py \
        ${worksrcpath}/test/dbus/monitor-test.py \
        ${worksrcpath}/test/dbus/remote-test.py \
        ${worksrcpath}/test/dbus/result-types-test.py \
        ${worksrcpath}/test/dbus/run-all-tests.py \
        ${worksrcpath}/test/dbus/upgrade-test.py \
        ${worksrcpath}/tools/development/index_switcher.py \
        ${worksrcpath}/tools/development/insert_events_from_json.py \
        ${worksrcpath}/tools/development/query_timings.py \
        ${worksrcpath}/tools/development/series.py \
        ${worksrcpath}/tools/development/slow_query_finder.py \
        ${worksrcpath}/tools/generate_events.py \
        ${worksrcpath}/tools/gtk/zeitgeist-data-sources-gtk.py \
        ${worksrcpath}/tools/ontology_graph.py \
        ${worksrcpath}/tools/scalability_benchmark.py \
        ${worksrcpath}/tools/talis  \
        ${worksrcpath}/tools/zeitgeist-explorer/zeitgeist-explorer
}

configure.cmd       ./autogen.sh
configure.args      --disable-silent-rules

livecheck.type      regex
livecheck.url       ${homepage}/refs
livecheck.regex     "id=v(\\d+(?:\\.\\d+)*)"