summaryrefslogtreecommitdiff
blob: 54e768a6a440811ca4f51bf85b5a665e7a6fc077 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
# Copyright 1999-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/net-analyzer/mtr/mtr-0.64.ebuild,v 1.1 2004/08/21 23:11:33 eldad Exp $

inherit eutils

IUSE="gtk gtk2"

DESCRIPTION="My TraceRoute. Excellent network diagnostic tool."
SRC_URI="ftp://ftp.bitwizard.nl/mtr/${P}.tar.gz"
HOMEPAGE="http://www.bitwizard.nl/mtr/"

DEPEND=">=sys-libs/ncurses-5.2
	gtk? ( !gtk2? ( =x11-libs/gtk+-1.2* )
		gtk2? ( >=x11-libs/gtk+-2* ) )"

SLOT="0"
LICENSE="GPL-2"
KEYWORDS="~x86 ~ppc ~sparc ~hppa ~alpha ~amd64"

src_compile() {
	local myconf
	use gtk || myconf="${myconf} --without-gtk"

	epatch ${FILESDIR}/mtr-ac-res_mkquery.patch
	autoconf

	econf ${myconf} \
		`use_enable gtk2` || die
	emake || die
}

src_install() {
	# this binary is universal. ie: it does both console and gtk.
	make DESTDIR=${D} sbindir=/usr/bin install || die

	fowners root:wheel /usr/bin/mtr
	fperms 4710 /usr/bin/mtr

	dodoc AUTHORS COPYING ChangeLog FORMATS NEWS README SECURITY TODO
}