# -*- 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 54832 2009-08-02 21:07:02Z dh@macports.org $

PortSystem          1.0
PortGroup           python26 1.0

name                py26-logilab-astng
version             0.19.0
revision            4
maintainers         dh openmaintainer
description         Python Abstract Syntax Tree New Generation
long_description    The aim of this module is to provide a common base representation of python source code for \
                    projects such as pychecker, pyreverse, pylint... Well, actually the development of this library \
                    is essentially governed by pylint's needs.

platforms           darwin

homepage            http://www.logilab.org/project/logilab-astng
master_sites        ftp://ftp.logilab.fr/pub/astng/
distname            logilab-astng-${version}

livecheck.url       http://ftp.logilab.org/pub/astng/
livecheck.check     regex
livecheck.regex     {logilab-astng-(\d+(?:\.\d+)*)\.tar\.gz}

checksums           md5     9478141bd45c1a1e72621797c94f18d3 \
                    sha1    87fe682ec98599c0088f228ba94cb50a7ed99466 \
                    rmd160  c9b4a2eabcd28e959315af33215d1620b405c475

depends_lib-append  port:py26-logilab-common

# these patches fix an issue in 0.19.0 where imports of PyQt4 fail to be recognised
# XXX: PROBABLY SHOULD BE REMOVED IN > 0.19.0 - I HAVE SUBMITTED UPSTREAM
patchfiles          patch-builder.py \
                    patch-raw_building.py
   
patch.pre_args      -l

post-destroot {
    xinstall -m 755 -d ${destroot}${prefix}/share/doc/${name}
    xinstall -m 644 -W ${worksrcpath} ChangeLog README \
        ${destroot}${prefix}/share/doc/${name}
    file delete ${destroot}/${python.prefix}/lib/python2.6/site-packages/logilab/__init__.py
}
