# -*- 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 64192 2010-02-24 22:23:31Z ryandesign@macports.org $

PortSystem          1.0

name                clutter
version             1.0.10
set branch          [string range $version 0 [expr [string last "." $version] - 1]]
categories          graphics
maintainers         devans openmaintainer
platforms           darwin
description         A generic high-level canvas library.
long_description    Clutter is an open source software library for \
                    creating fast, visually rich and animated graphical \
                    user interfaces.
homepage            http://www.clutter-project.org/
master_sites        http://www.clutter-project.org/sources/${name}/${branch}/
use_bzip2           yes

checksums           md5     bf48e85291cba33f3f149f4eefe759f0 \
                    sha1    189684f0346bb895a2b47da64c02260c67e2810e \
                    rmd160  7738b2603298a687bfa056f458e84080bc880d1e

depends_build       port:pkgconfig

depends_lib         port:gtk2 \
                    port:mesa \
                    port:xorg-libXdamage \
                    port:xorg-libXcomposite

configure.args      --with-flavour=glx \
                    --with-imagebackend=gdk-pixbuf \
                    --x-includes=${prefix}/include \
                    --x-libraries=${prefix}/include \
                    --enable-introspection=no \
                    --disable-gtk-doc

variant no_x11 {
    depends_lib-delete   port:mesa \
                         port:xorg-libXdamage \
                         port:xorg-libXcomposite
    configure.args-delete --with-flavour=glx \
                         --with-imagebackend=gdk-pixbuf \
                         --x-includes=${prefix}/include \
                         --x-libraries=${prefix}/include
    configure.args-append --with-flavour=osx
}

livecheck.type      regex
livecheck.url       http://www.clutter-project.org/sources/${name}/${branch}/
livecheck.regex     "${name}-(\\d+(?:\\.\\d+)*)${extract.suffix}"
