diff --git a/pkgs/os-specific/linux/pam/default.nix b/pkgs/os-specific/linux/pam/default.nix index 3de7916bff6..fc2a7ea61d2 100644 --- a/pkgs/os-specific/linux/pam/default.nix +++ b/pkgs/os-specific/linux/pam/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, flex, cracklib }: +{ stdenv, buildPackages, fetchurl, flex, cracklib }: stdenv.mkDerivation rec { name = "linux-pam-${version}"; @@ -11,7 +11,7 @@ stdenv.mkDerivation rec { outputs = [ "out" "doc" "man" /* "modules" */ ]; - nativeBuildInputs = [ flex ]; + nativeBuildInputs = [ buildPackages.stdenv.cc flex ]; buildInputs = [ cracklib ]; @@ -20,7 +20,7 @@ stdenv.mkDerivation rec { crossAttrs = { propagatedBuildInputs = [ flex.crossDrv cracklib.crossDrv ]; preConfigure = preConfigure + '' - ar x ${flex.crossDrv}/lib/libfl.a + $crossConfig-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