From c5e3472e2072ed0998571ce3961b8df65e2862cc Mon Sep 17 00:00:00 2001 From: Bernardo Meurer Date: Sun, 26 Apr 2020 13:11:24 -0700 Subject: [PATCH] coreutils: set ac_cv_func_lchmod=no Bumping binutils to 2.32 broke coreutils for unknown reasons[1]. Upon further investigation we found that there was some issue with mknod inside a chroot[2][3], which setting ac_cv_func_lchmod to "no" _somehow_ fixes. We apply this fix and hope to never have to debug this again. Thanks to @flokli and @lnl7 who helped me chase after this and @pbogdan who found the fix in the fedora build. [1]: https://github.com/NixOS/nixpkgs/pull/85951 [2]: https://github.com/NixOS/nixpkgs/pull/85951#issuecomment-619601978 [3]: https://bugzilla.redhat.com/show_bug.cgi?id=1811038 --- pkgs/tools/misc/coreutils/default.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/pkgs/tools/misc/coreutils/default.nix b/pkgs/tools/misc/coreutils/default.nix index 49edc002bec..b39bef7cb2d 100644 --- a/pkgs/tools/misc/coreutils/default.nix +++ b/pkgs/tools/misc/coreutils/default.nix @@ -79,6 +79,7 @@ stdenv.mkDerivation (rec { ++ optional (singleBinary != false) ("--enable-single-binary" + optionalString (isString singleBinary) "=${singleBinary}") ++ optional withOpenssl "--with-openssl" + ++ optional stdenv.hostPlatform.isLinux "ac_cv_func_lchmod=no" ++ optional stdenv.hostPlatform.isSunOS "ac_cv_func_inotify_init=no" ++ optional withPrefix "--program-prefix=g" ++ optionals (stdenv.hostPlatform != stdenv.buildPlatform && stdenv.hostPlatform.libc == "glibc") [