From 54061e617382ad2ab79f0989f5219d13cb52546c Mon Sep 17 00:00:00 2001 From: Michael Raskin <7c6f434c@mail.ru> Date: Sun, 17 Jun 2007 22:34:44 +0000 Subject: [PATCH] Added lsof - "list open files" tool svn path=/nixpkgs/trunk/; revision=8885 --- pkgs/development/tools/misc/lsof/default.nix | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 pkgs/development/tools/misc/lsof/default.nix diff --git a/pkgs/development/tools/misc/lsof/default.nix b/pkgs/development/tools/misc/lsof/default.nix new file mode 100644 index 000000000000..012f5259c5ce --- /dev/null +++ b/pkgs/development/tools/misc/lsof/default.nix @@ -0,0 +1,15 @@ + +pkgs: +pkgs.stdenv.mkDerivation { + name = "lsof"; + + src = pkgs.fetchurl { + url = ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/lsof_4.78.tar.bz2; + sha256 = "0azvl43niqkq94drx52p6dvp70r38f25fqw181ywmvqn80dbb3c9"; + }; + + unpackPhase = "tar xvjf $src; cd lsof_*; tar xvf lsof_*.tar; sourceRoot=lsof_*; "; + configurePhase = "./Configure -n linux;"; + preBuild = "sed -i Makefile -e 's/^CFGF=/& -DHASIPv6=1/;';"; + installPhase = " mkdir -p $out/bin $out/man/man8; cp lsof.8 $out/man/man8/; cp lsof $out/bin"; +}