2010-03-10 23:22:43 +01:00
|
|
|
{ stdenv, fetchurl, libpcap, enableStatic ? false }:
|
2007-01-16 15:35:08 +01:00
|
|
|
|
2008-09-01 15:00:24 +02:00
|
|
|
stdenv.mkDerivation rec {
|
2010-04-04 16:57:26 +02:00
|
|
|
name = "tcpdump-4.1.0";
|
2008-09-01 15:00:24 +02:00
|
|
|
|
2007-01-16 15:35:08 +01:00
|
|
|
src = fetchurl {
|
2010-02-05 23:00:51 +01:00
|
|
|
url = "http://www.tcpdump.org/release/${name}.tar.gz";
|
2010-04-04 16:57:26 +02:00
|
|
|
sha256 = "1yhmz23cb0qx16nwnmyk2v7nnqai20lzcc4lx34v728qdpkmc1in";
|
2007-01-16 15:35:08 +01:00
|
|
|
};
|
2008-09-01 15:00:24 +02:00
|
|
|
|
2010-02-05 23:00:51 +01:00
|
|
|
buildInputs = [ libpcap ];
|
2008-09-01 15:00:24 +02:00
|
|
|
|
2010-03-10 23:22:43 +01:00
|
|
|
crossAttrs = {
|
|
|
|
LDFLAGS = if enableStatic then "-static" else "";
|
|
|
|
configureFlags = [ "ac_cv_linux_vers=2" ] ++ (stdenv.lib.optional
|
|
|
|
(stdenv.cross.platform.kernelMajor == "2.4") "--disable-ipv6");
|
|
|
|
};
|
|
|
|
|
2008-09-01 15:00:24 +02:00
|
|
|
meta = {
|
|
|
|
description = "tcpdump, a famous network sniffer";
|
|
|
|
homepage = http://www.tcpdump.org/;
|
|
|
|
license = "BSD-style";
|
|
|
|
};
|
2007-01-16 15:35:08 +01:00
|
|
|
}
|