diff options
author | Peter Hoeg <peter@hoeg.com> | 2017-09-14 18:13:47 +0800 |
---|---|---|
committer | Peter Hoeg <peter@hoeg.com> | 2017-09-14 18:14:19 +0800 |
commit | 68764d50b33da158e1c5aea1052cc7e271faaa42 (patch) | |
tree | b54b60740ae445aa3ca9fadee6bb7cd30b6d1d17 /pkgs/tools | |
parent | 2a36c6c18543cbfa540b76ba72b71e110e07b617 (diff) |
mtr: 0.87 -> 0.92
Diffstat (limited to 'pkgs/tools')
-rw-r--r-- | pkgs/tools/networking/mtr/default.nix | 40 |
1 files changed, 23 insertions, 17 deletions
diff --git a/pkgs/tools/networking/mtr/default.nix b/pkgs/tools/networking/mtr/default.nix index 03a0c99c42135..8932360c7176c 100644 --- a/pkgs/tools/networking/mtr/default.nix +++ b/pkgs/tools/networking/mtr/default.nix @@ -1,34 +1,40 @@ -{stdenv, fetchurl, autoreconfHook, pkgconfig, ncurses -, withGtk ? false, gtk2 ? null}: +{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, ncurses +, withGtk ? false, gtk2 ? null }: assert withGtk -> gtk2 != null; -with stdenv.lib; stdenv.mkDerivation rec { - baseName="mtr"; - version="0.87"; - name="${baseName}-${version}"; - - src = fetchurl { - url="ftp://ftp.bitwizard.nl/${baseName}/${name}.tar.gz"; - sha256 = "17zi99n8bdqrwrnbfyjn327jz4gxx287wrq3vk459c933p34ff8r"; + name="mtr-${version}"; + version="0.92"; + + src = fetchFromGitHub { + owner = "traviscross"; + repo = "mtr"; + rev = "v${version}"; + sha256 = "0ca2ml846cv0zzkpd8y7ah6i9b3czrr8wlxja3cray94ybwb294d"; }; - preConfigure = "substituteInPlace Makefile.in --replace ' install-exec-hook' ''"; + preConfigure = '' + echo ${version} > .tarball-version + + ./bootstrap.sh + + substituteInPlace Makefile.in --replace ' install-exec-hook' "" + ''; - configureFlags = optionalString (!withGtk) "--without-gtk"; + configureFlags = stdenv.lib.optionalString (!withGtk) "--without-gtk"; nativeBuildInputs = [ autoreconfHook pkgconfig ]; - buildInputs = [ ncurses ] ++ optional withGtk gtk2; + buildInputs = [ ncurses ] ++ stdenv.lib.optional withGtk gtk2; enableParallelBuilding = true; - meta = { - homepage = http://www.bitwizard.nl/mtr/; + 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; - license = licenses.gpl2; + platforms = platforms.unix; }; } |