# $Id: Portfile 302 2011-07-31 15:18:15Z kimuraw $

PortSystem      1.0
name            apr-util-rast
version         1.2.2
revision        1
categories      devel
maintainers     rsky0711@gmail.com
description     apr-util for Rast (linked to db-4.6)
long_description \
    apr-util is a library of useful utilities built with \
    and intended to be used with the Apache Portable Runtime.
platforms		darwin
homepage        http://apr.apache.org/
dist_subdir     apr-util
distfiles       apr-util-${version}.tar.bz2
worksrcdir      apr-util-${version}
master_sites    apache:apr
checksums       md5 694228b227e30cb9da3823514516e91c \
                sha1 1928fde55a81cef07c6e60bfa3d796d26f534f48 \
                rmd160 45530d20658d7b205525b692b4fcbe09fc1f3200

use_bzip2       yes

depends_lib     port:apr-rast port:expat port:libiconv port:db46

configure.env   CPPFLAGS="-I${prefix}/include/db46 -I${prefix}/include/apr-rast -I${prefix}/include" \
                LDFLAGS="-L${prefix}/lib/db46 -L${prefix}/lib/apr-rast -L${prefix}/lib" \
                APRUTIL_INCLUDES="-I${prefix}/include/db46 -I${prefix}/include/apr-rast" \
                APRUTIL_LDFLAGS="-L${prefix}/lib/db46 -L${prefix}/lib/apr-rast"
configure.args  --prefix=${prefix}/lib/${name} \
                --bindir=${prefix}/lib/${name}/bin \
                --libdir=${prefix}/lib/${name} \
                --includedir=${prefix}/include/${name} \
                --with-apr=${prefix}/lib/apr-rast/bin/apr-1-config \
                --with-expat=${prefix} --with-iconv=${prefix} \
                --with-dbm=db --with-berkeley-db \
                --without-mysql --without-pgsql \
                --without-sqlite2 --without-sqlite3
