# Copyright 1999-2011 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ EAPI=3 inherit qt4-r2 DESCRIPTION="MoNav is a Desktop / Mobile application that offers state-of-the-art fast and exact routing with OpenStreetMap Data." HOMEPAGE="http://code.google.com/p/monav/" SRC_URI="http://monav.googlecode.com/files/monav-${PV}.tar.gz" LICENSE="GPL-3" SLOT="0" KEYWORDS="~amd64" IUSE="monav-client +preprocessor preprocessor-gui" REQUIRED_USE="preprocessor? ( preprocessor-gui )" DEPEND="x11-libs/qt-core:4 preprocessor-gui? ( monav-client? ( x11-libs/qt-gui:4 ) x11-libs/qt-mobility[location] ) preprocessor? ( dev-libs/libxml2 app-arch/bzip2 sci-geosciences/mapnik dev-libs/protobuf )" RDEPEND="${DEPEND}" src_unpack() { unpack ${A} cd "${S}" epatch "${FILESDIR}"/${P}-qmake.patch } src_configure() { eqmake4 "${S}"/monavroutingdaemon.pro CONFIG+=nogui -o "${S}"/Makefile.routingdaemon if use preprocessor ; then eqmake4 "${S}"/monavpreprocessor.pro CONFIG+=nogui -o "${S}"/Makefile.preprocessor fi if use preprocessor-gui ; then eqmake4 "${S}"/monavpreprocessor-gui.pro -o "${S}"/Makefile.preprocessor-gui fi if use monav-client ; then eqmake4 "${S}"/monavclient.pro -o "${S}"/Makefile.client fi } src_compile() { emake -f "${S}"/Makefile.routingdaemon if use preprocessor ; then emake -f "${S}"/Makefile.preprocessor fi if use preprocessor-gui ; then emake -f "${S}"/Makefile.preprocessor-gui fi if use monav-client ; then emake -f "${S}"/Makefile.client fi } src_install() { dobin bin/daemon-test || die dobin bin/monav-daemon || die if use preprocessor ; then dobin bin/monav-preprocessor || die fi if use preprocessor-gui ; then dobin bin/monav-preprocessor-gui || die fi if use monav-client ; then dobin bin/monav || die fi }