# Copyright 1999-2007 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: inherit eutils qt4 QCA_VER="2.0-test3" MY_PV="${PV/_p/-}" MY_P="${PN}-${MY_PV}" DESCRIPTION="Logger plugin for QCA" HOMEPAGE="http://delta.affinix.com/qca/" SRC_URI="http://delta.affinix.com/download/qca/${QCA_VER/-*/}/${QCA_VER/*-/}/${MY_P}.tar.bz2" LICENSE="LGPL-2" SLOT="2" KEYWORDS="~amd64 ~x86" IUSE="debug" RESTRICT="strip" RDEPEND=">=app-crypt/qca-2.0.0_rc2" DEPEND="${RDEPEND}" S="${WORKDIR}/${MY_P}" pkg_setup() { if use debug && ! built_with_use '>=app-crypt/qca-2.0.0_rc' debug; then einfo einfo "You are trying to compile ${PN} package with active USE=\"debug\"" einfo "while qca is build without this particular flag. It will not" einfo "work." einfo einfo "Possible solutions to this problem are:" einfo "a) install package ${PN} without debug USE flag" einfo "b) re-emerge qca with debug USE flag" einfo die "can't emerge ${PN} with debug USE flag" fi } src_compile() { local myconf= if use debug; then myconf="--debug-and-release" else myconf="--release" fi ./configure \ --qtdir=/usr \ --no-separate-debug-info \ ${myconf} || die "configure failed" eqmake4 ${PN}.pro emake || die "make failed" } src_install() { emake INSTALL_ROOT="${D}" install || die "make install failed" dodoc README }