# Copyright 1999-2006 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ EAPI="1" inherit cmake-utils eutils DESCRIPTION="Qt4-based download/upload manager" HOMEPAGE="http://fatrat.dolezel.info/" SRC_URI="http://www.dolezel.info/download/data/${PN}/${P}.tar.bz2" LICENSE="GPL-2" SLOT="0" KEYWORDS="~x86 ~amd64" IUSE="+bittorrent doc -debug jabber nls sftp" RESTRICT="mirror" DEPEND="|| ( x11-libs/qt-gui:4 =x11-libs/qt-4.3* ) bittorrent? ( >=net-libs/rb_libtorrent-0.13_pre1683 ) doc? ( x11-libs/qt-assistant:4 ) jabber? ( net-libs/gloox ) sftp? ( net-libs/libssh2 )" RDEPEND="${DEPEND}" pkg_setup() { echo einfo "If you want the GeoIP support, then emerge dev-libs/geoip." echo local missing_ssl="false" if has_version x11-libs/qt-core; then built_with_use x11-libs/qt-core ssl || missing_ssl="true" elif ! built_with_use x11-libs/qt ssl; then missing_ssl="true" fi if $missing_ssl; then die "You need a Qt 4 compiled with the SSL support." fi } src_compile() { local myconf="" use debug && myconf="-DCMAKE_BUILD_TYPE=Debug" cmake . \ -DCMAKE_INSTALL_PREFIX="/usr" \ $(cmake-utils_use_with bittorrent BITTORRENT) \ $(cmake-utils_use_with doc DOCUMENTATION) \ $(cmake-utils_use_with jabber JABBER) \ $(cmake-utils_use_with nls NLS) \ $(cmake-utils_use_with sftp SFTP) \ ${myconf} emake || die "make failed" } src_install() { emake DESTDIR="${D}" install || die "make install failed" }