From 9bbc709586f77a1bcf8d9aac3a4f7f91314a4f6b Mon Sep 17 00:00:00 2001 From: David McFarland Date: Fri, 19 Sep 2025 11:24:47 -0300 Subject: [PATCH] cc-wrapper: set gl_cv_clean_version_stddef=yes on cygwin --- pkgs/build-support/cc-wrapper/default.nix | 4 ++++ pkgs/development/libraries/libidn2/default.nix | 6 ------ pkgs/tools/text/gnugrep/default.nix | 5 ----- 3 files changed, 4 insertions(+), 11 deletions(-) diff --git a/pkgs/build-support/cc-wrapper/default.nix b/pkgs/build-support/cc-wrapper/default.nix index fe23d342a014..07efab5e75c1 100644 --- a/pkgs/build-support/cc-wrapper/default.nix +++ b/pkgs/build-support/cc-wrapper/default.nix @@ -603,6 +603,10 @@ stdenvNoCC.mkDerivation { if targetPlatform.isCygwin then '' echo addToSearchPath "LINK_DLL_FOLDERS" "${cc_bin}/lib" >> $out + # Work around build failure caused by the gnulib workaround for + # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114870. remove after + # gnulib is updated in core packages (e.g. iconv, gnupatch, gnugrep) + echo appendToVar configureFlags gl_cv_clean_version_stddef=yes >> $out '' else '' diff --git a/pkgs/development/libraries/libidn2/default.nix b/pkgs/development/libraries/libidn2/default.nix index c131f5afa902..067eee12bbef 100644 --- a/pkgs/development/libraries/libidn2/default.nix +++ b/pkgs/development/libraries/libidn2/default.nix @@ -44,12 +44,6 @@ stdenv.mkDerivation rec { buildInputs = [ libunistring ] ++ lib.optional stdenv.hostPlatform.isDarwin libiconv; depsBuildBuild = [ buildPackages.stdenv.cc ]; - configureFlags = - # Work around build failure caused by the gnulib workaround for - # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114870. - # remove after gnulib is updated - lib.optional stdenv.hostPlatform.isCygwin "gl_cv_clean_version_stddef=yes"; - meta = { homepage = "https://www.gnu.org/software/libidn/#libidn2"; description = "Free software implementation of IDNA2008 and TR46"; diff --git a/pkgs/tools/text/gnugrep/default.nix b/pkgs/tools/text/gnugrep/default.nix index aab61444b524..d22e3434d738 100644 --- a/pkgs/tools/text/gnugrep/default.nix +++ b/pkgs/tools/text/gnugrep/default.nix @@ -80,11 +80,6 @@ stdenv.mkDerivation { export MKDIR_P="mkdir -p" ''; - configureFlags = - # Work around build failure caused by the gnulib workaround for - # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114870. remove after GCC 15 - lib.optional stdenv.hostPlatform.isCygwin "gl_cv_clean_version_stddef=yes"; - enableParallelBuilding = true; # Fix reference to sh in bootstrap-tools, and invoke grep via