summary refs log tree commit diff
path: root/pkgs/tools/security/mkpasswd
diff options
context:
space:
mode:
authorFranz Pletz <fpletz@fnordicwalking.de>2015-05-25 00:53:10 +0200
committerVladimír Čunát <vcunat@gmail.com>2015-11-11 15:26:10 +0100
commit03959d46165f49e6c3629cf1bf2a9ce0f6933de3 (patch)
tree397558db5bb56e2dfbdabacf8acacb99d3dc89a9 /pkgs/tools/security/mkpasswd
parente8ee8496e5b79c1effebcb13bd5b2f241360c288 (diff)
downloadnixpkgs-03959d46165f49e6c3629cf1bf2a9ce0f6933de3.tar
nixpkgs-03959d46165f49e6c3629cf1bf2a9ce0f6933de3.tar.gz
nixpkgs-03959d46165f49e6c3629cf1bf2a9ce0f6933de3.tar.bz2
nixpkgs-03959d46165f49e6c3629cf1bf2a9ce0f6933de3.tar.lz
nixpkgs-03959d46165f49e6c3629cf1bf2a9ce0f6933de3.tar.xz
nixpkgs-03959d46165f49e6c3629cf1bf2a9ce0f6933de3.tar.zst
nixpkgs-03959d46165f49e6c3629cf1bf2a9ce0f6933de3.zip
whois: init at 5.2.10 and share with mkpasswd
Close #7979.
This commit adds a much more usable whois tool compared to the ones in
busybox and inetutils.

The sources for whois and mkpasswd from Debian are both located in the whois
git repository for historical reasons.
Diffstat (limited to 'pkgs/tools/security/mkpasswd')
-rw-r--r--pkgs/tools/security/mkpasswd/default.nix23
1 files changed, 7 insertions, 16 deletions
diff --git a/pkgs/tools/security/mkpasswd/default.nix b/pkgs/tools/security/mkpasswd/default.nix
index 8975ca4324d..88aa71810dc 100644
--- a/pkgs/tools/security/mkpasswd/default.nix
+++ b/pkgs/tools/security/mkpasswd/default.nix
@@ -1,30 +1,21 @@
-{ stdenv, fetchFromGitHub }:
+{ stdenv, whois, perl }:
 
-stdenv.mkDerivation rec {
-  name = "mkpasswd-${version}";
+stdenv.mkDerivation {
+  name = "mkpasswd-${whois.version}";
 
-  version = "5.1.1";
+  src = whois.src;
 
-  src = fetchFromGitHub {
-    owner = "rfc1036";
-    repo = "whois";
-    rev = "v${version}";
-    sha256 = "026x8byx8pcpkdxca64368p0nlspk4phw18jg4p04di6cg6nc1m5";
-  };
-
-  preConfigure = ''
-    substituteInPlace Makefile --replace "prefix = /usr" "prefix = $out"
-  '';
+  buildInputs = [ perl ];
 
+  preConfigure = whois.preConfigure;
   buildPhase = "make mkpasswd";
-
   installPhase = "make install-mkpasswd";
 
   meta = with stdenv.lib; {
     homepage = http://packages.qa.debian.org/w/whois.html;
     description = "Overfeatured front-end to crypt, from the Debian whois package";
     license = licenses.gpl2;
-    maintainers = [ maintainers.cstrahan ];
+    maintainers = with maintainers; [ cstrahan fpletz ];
     platforms = platforms.linux;
   };
 }