summary refs log tree commit diff
path: root/pkgs/os-specific/linux/pam/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/os-specific/linux/pam/default.nix')
-rw-r--r--pkgs/os-specific/linux/pam/default.nix25
1 files changed, 11 insertions, 14 deletions
diff --git a/pkgs/os-specific/linux/pam/default.nix b/pkgs/os-specific/linux/pam/default.nix
index 7da03cf9cad9..43300425c004 100644
--- a/pkgs/os-specific/linux/pam/default.nix
+++ b/pkgs/os-specific/linux/pam/default.nix
@@ -1,24 +1,21 @@
-{ stdenv, fetchurl, flex, cracklib, libxcrypt }:
+{ stdenv, fetchurl, flex, cracklib }:
 
 stdenv.mkDerivation rec {
-  name = "linux-pam-1.1.1";
+  name = "linux-pam-1.1.6";
 
   src = fetchurl {
-    url = http://www.linux-pam.org/library/Linux-PAM-1.1.1.tar.bz2;
-    sha256 = "015r3xdkjpqwcv4lvxavq0nybdpxhfjycqpzbx8agqd5sywkx3b0";
+    url = https://fedorahosted.org/releases/l/i/linux-pam/Linux-PAM-1.1.6.tar.bz2;
+    sha256 = "1hlz2kqvbjisvwyicdincq7nz897b9rrafyzccwzqiqg53b8gf5s";
   };
 
-  buildNativeInputs = [ flex ];
-  buildInputs = [ cracklib ]
-    ++ stdenv.lib.optional
-      (!stdenv.isArm && stdenv.system != "mips64el-linux")
-      libxcrypt;
+  nativeBuildInputs = [ flex ];
+
+  buildInputs = [ cracklib ];
 
   crossAttrs = {
-    # Skip libxcrypt cross-building, as it fails for mips and arm
-    propagatedBuildInputs = [ flex.hostDrv cracklib.hostDrv ];
+    propagatedBuildInputs = [ flex.crossDrv cracklib.crossDrv ];
     preConfigure = preConfigure + ''
-      ar x ${flex.hostDrv}/lib/libfl.a
+      ar x ${flex.crossDrv}/lib/libfl.a
       mv libyywrap.o libyywrap-target.o
       ar x ${flex}/lib/libfl.a
       mv libyywrap.o libyywrap-host.o
@@ -27,13 +24,13 @@ stdenv.mkDerivation rec {
     '';
     postConfigure = ''
       sed -e "s@ $PWD/libyywrap-target.o@ $PWD/libyywrap-host.o@" -i doc/specs/Makefile
-    ''; 
+    '';
   };
 
   postInstall = ''
     mv -v $out/sbin/unix_chkpwd{,.orig}
     ln -sv /var/setuid-wrappers/unix_chkpwd $out/sbin/unix_chkpwd
-    '';
+  '';
 
   preConfigure = ''
     configureFlags="$configureFlags --includedir=$out/include/security"