# -*- 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 100189 2012-12-03 07:53:55Z ryandesign@macports.org $

PortSystem          1.0

name                talloc
conflicts           samba3
version             2.0.8
set major           [lindex [split ${version} .] 0]
categories          devel
# mostly LGPL, but a few files are GPL
license             GPL-3+
platforms           darwin
maintainers         nomaintainer
description         Hierarchical memory allocation library
long_description    talloc is a hierarchical, reference counted memory pool \
                    system with destructors. It is the core memory allocator \
                    used in Samba.
homepage            http://talloc.samba.org/
master_sites        http://www.samba.org/ftp/talloc/

checksums           rmd160  76a5721fdef6102f692aaa5982302b6bd479b8f1 \
                    sha256  1ec11e635e0318dbbb014db38ff96e8dba3ce5f614eeb7d993b4a5b71c016783

configure.args      --disable-python \
                    --with-libiconv=${prefix} \
                    --with-gettext=${prefix}

# disable silent rules
build.args          V=1
destroot.args       V=1

post-destroot {
    system "install_name_tool -id ${prefix}/lib/libtalloc.${major}.dylib ${destroot}${prefix}/lib/libtalloc.${major}.dylib"
}

livecheck.type      regex
livecheck.url       [lindex ${master_sites} 0]
livecheck.regex     ${name}-(\[0-9.\]+)${extract.suffix}
