# -*- 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 84112 2011-09-17 16:17:46Z adfernandes@macports.org $

PortSystem      1.0
PortGroup       python27 1.0

set myname      pylibelf
name            py27-${myname}
version         0.1.20110915
categories-append   devel
platforms       darwin
maintainers     adfernandes openmaintainer
description     Pythonic wrapper for the libelf library.

long_description \
    ${description}

homepage    http://eggy.yolky.org/pylibelf/static/docs/index.html
fetch.type  hg
hg.url      https://bitbucket.org/eggy/pylibelf
hg.tag      81d39db22cbd
worksrcdir  ${name}-${version}

patch.pre_args  -p1
patchfiles      setup.diff

post-patch {
    reinplace "s|@@PREFIX@@|${prefix}|g" \
        ${worksrcpath}/setup.py \
        ${worksrcpath}/constfile2cython.py
}

depends_lib-append  port:py27-cython port:py27-ply

livecheck.type  regex
livecheck.regex ${myname}\\s+v\\d+(.\\d+)\\s+documentation
