# Copyright 1999-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /cvsroot/dev/portage/net-www/modfw/modfw-0.1.9.ebuild,v 1.2 2004/12/09 18:31:20 joerg Exp $

inherit flag-o-matic eutils toolchain-funcs

VERSION="0.2.0-alpha4"
FILE="CDB-${VERSION}.tar.gz"
DESCRIPTION="CDB - Easy to use abtraction of database client libraries"
SRC_URI="http://ffdev.hirnbrei.org/dist/${FILE}
http://ffdev.hirnbrei.org/dist/CDB_error_handling.patch"
HOMEPAGE="http://c-db.sf.net"
KEYWORDS="~x86 ~amd64"
LICENSE="GPL-2"
SLOT="0"
IUSE="pgsql sqlite mysql"
S="${WORKDIR}/CDB-${VERSION}"

DEPEND="pgsql? ( dev-db/postgresql )
	sqlite? ( dev-db/sqlite )
	mysql? ( dev-db/mysql )"
RDEPEND="pgsql? ( dev-db/postgresql )
	sqlite? ( dev-db/sqlite )
	mysql? ( dev-db/mysql )"

src_unpack() {
	unpack ${FILE} || die
	epatch ${DISTDIR}/CDB_error_handling.patch
}

src_compile() {
	econf || die
	emake || die "make failed"
}

src_install() {
	einstall || die
}