blob: 3c2ced1712fd0b53ec3029ab2f2b235fdaa9b528 (
plain) (
blame)
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
|
{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, ncurses
, withGtk ? false, gtk2 ? null }:
assert withGtk -> gtk2 != null;
stdenv.mkDerivation rec {
name="mtr-${version}";
version="0.92";
src = fetchFromGitHub {
owner = "traviscross";
repo = "mtr";
rev = "v${version}";
sha256 = "0ca2ml846cv0zzkpd8y7ah6i9b3czrr8wlxja3cray94ybwb294d";
};
preConfigure = ''
echo ${version} > .tarball-version
./bootstrap.sh
substituteInPlace Makefile.in --replace ' install-exec-hook' ""
'';
configureFlags = stdenv.lib.optional (!withGtk) "--without-gtk";
nativeBuildInputs = [ autoreconfHook pkgconfig ];
buildInputs = [ ncurses ] ++ stdenv.lib.optional withGtk gtk2;
enableParallelBuilding = true;
meta = with stdenv.lib; {
description = "A network diagnostics tool";
homepage = http://www.bitwizard.nl/mtr/;
license = licenses.gpl2;
maintainers = with maintainers; [ koral orivej raskin ];
platforms = platforms.unix;
};
}
|