# -*- 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
# $Id: Portfile 67882 2010-05-20 17:15:17Z ryandesign@macports.org $

PortSystem      1.0

name            vte
version         0.25.1
set branch      [join [lrange [split $version .] 0 1] .]
maintainers     nomaintainer
categories      gnome
platforms       darwin
description     Terminal widget with improved accessibility and I18N support.

long_description \
    Terminal widget with improved font, internationalisation and \
    accessibility support for the GNOME 2 desktop.  Designed to \
    replace libzvt.

homepage        http://www.gnome.org/
master_sites    gnome:sources/$name/$branch/
use_bzip2       yes

checksums       md5     986bdf8f4e25bdb30615b69b26289909 \
                sha1    818130a91bc205c3165aa380dae43d12b733a406 \
                rmd160  cfb094f4055dd98e3cfd6053efa2119034c81295

depends_lib     port:py26-gtk \
                port:gtk2 \
                port:ncurses

depends_build   port:p5-xml-parser \
                port:intltool \
                port:pkgconfig

if { ![file exists ${prefix}/include/gtk-2.0/gdk/gdkx.h] } {
    patchfiles patch-x-display-missing.diff
}

configure.args  --disable-freetypetest
configure.python ${prefix}/bin/python2.6

configure.cflags-append -fstrict-aliasing

use_parallel_build  yes

variant without_python description {Disable Python support} {
    depends_lib-delete  port:py26-gtk
    configure.args-append   --disable-python
}

platform darwin 9 {
    post-patch {
        reinplace "s| -export-symbols-regex.*||g" \
            ${worksrcpath}/python/Makefile.in
        reinplace "s|-export-symbols-regex.*| \\\\|g" \
            ${worksrcpath}/src/Makefile.in
    }
}

livecheck.type  regex
livecheck.url   http://ftp.gnome.org/pub/gnome/sources/$name/$branch/
livecheck.regex {LATEST-IS-(\d+(?:\.\d+)*)}
