about summary refs log tree commit diff
path: root/nixpkgs/pkgs/tools/networking/tcptraceroute/default.nix
blob: 379caedaaf1bf5ab61387a0844930aa4b33989bb (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
{ lib
, stdenv
, fetchFromGitHub
, libpcap
, libnet
}:

stdenv.mkDerivation rec {
  pname = "tcptraceroute";
  version = "1.5beta7";

  src = fetchFromGitHub {
    owner = "mct";
    repo = "tcptraceroute";
    rev = "${pname}-${version}";
    hash = "sha256-KU4MLWtOFzzNr+I99fRbhBokhS1JUNL+OgVltkOGav4=";
  };


  # for reasons unknown --disable-static configure flag doesn't disable static
  # linking.. we instead override CFLAGS with -static omitted
  preBuild = ''
    makeFlagsArray=(CFLAGS=" -g -O2 -Wall")
  '';

  buildInputs = [ libpcap libnet ];

  meta = {
    description = "A traceroute implementation using TCP packets";
    homepage = "https://github.com/mct/tcptraceroute";
    license = lib.licenses.gpl2;
    maintainers = [ ];
  };
}