nixpkgs/pkgs/tools/networking/tcpdump/default.nix
William A. Kennington III ce9f2d5720 tcpdump: 4.6.2 -> 4.7.3
2015-03-26 14:03:52 -07:00

27 lines
728 B
Nix

{ stdenv, fetchurl, libpcap, enableStatic ? false }:
stdenv.mkDerivation rec {
name = "tcpdump-4.7.3";
src = fetchurl {
url = "http://www.tcpdump.org/release/${name}.tar.gz";
sha256 = "1kla3l7lja8cfwimp512x7z176x2dsy03ih6g8gd95p95ijzp1qz";
};
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";
maintainers = [ stdenv.lib.maintainers.mornfall ];
platforms = stdenv.lib.platforms.linux;
};
}