diff --git a/pkgs/tools/misc/coreutils/default.nix b/pkgs/tools/misc/coreutils/default.nix index ec6be06ede3..8b39e3711e1 100644 --- a/pkgs/tools/misc/coreutils/default.nix +++ b/pkgs/tools/misc/coreutils/default.nix @@ -54,13 +54,13 @@ let ++ optional (stdenv.ccCross.libc ? libiconv) stdenv.ccCross.libc.libiconv.crossDrv; - buildPhase = '' - make || ( - pushd man - for a in *.x; do - touch `basename $a .x`.1 - done - popd; make ) + # Prevents attempts of running 'help2man' on cross-built binaries. + PERL = "missing"; + + # Works around a bug with 8.26: + # Makefile:3440: *** Recursive variable 'INSTALL' references itself (eventually). Stop. + preInstall = '' + sed -i Makefile -e 's|^INSTALL =.*|INSTALL = ${self}/bin/install -c|' ''; postInstall = ''