nixpkgs-suyu/pkgs/tools/networking/tcpdump/default.nix

27 lines
742 B
Nix
Raw Normal View History

{ stdenv, fetchurl, libpcap, enableStatic ? false }:
stdenv.mkDerivation rec {
2017-01-22 01:44:38 +01:00
name = "tcpdump-4.8.1";
src = fetchurl {
url = "http://www.tcpdump.org/release/${name}.tar.gz";
2017-01-22 01:44:38 +01:00
sha256 = "0743ipl0l7ymjss3ybvvc5cbk9kb7s8yl4p3ramp5kwgqhg39r10";
};
buildInputs = [ libpcap ];
crossAttrs = {
LDFLAGS = if enableStatic then "-static" else "";
configureFlags = [ "ac_cv_linux_vers=2" ] ++ (stdenv.lib.optional
(stdenv.cross.platform.kernelMajor == "2.4") "--disable-ipv6");
};
meta = {
description = "Network sniffer";
homepage = http://www.tcpdump.org/;
license = "BSD-style";
2015-06-22 08:25:07 +02:00
maintainers = with stdenv.lib.maintainers; [ mornfall jgeerds ];
platforms = stdenv.lib.platforms.linux;
};
}