From 2ccfa5f18739cf5f7d7a120a8d8aceb075fd023a Mon Sep 17 00:00:00 2001 From: oech3 <79379754+oech3@users.noreply.github.com> Date: Mon, 24 Nov 2025 20:50:34 +0900 Subject: [PATCH 1/2] build-gnu.sh: Reduce time to build GNU coreutils --- util/build-gnu.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/util/build-gnu.sh b/util/build-gnu.sh index 46a2852ef72..cc8e9d60823 100755 --- a/util/build-gnu.sh +++ b/util/build-gnu.sh @@ -4,7 +4,7 @@ # spell-checker:ignore (paths) abmon deref discrim eacces getlimits getopt ginstall inacc infloop inotify reflink ; (misc) INT_OFLOW OFLOW # spell-checker:ignore baddecode submodules xstrtol distros ; (vars/env) SRCDIR vdir rcexp xpart dired OSTYPE ; (utils) gnproc greadlink gsed multihardlink texinfo CARGOFLAGS -# spell-checker:ignore openat TOCTOU +# spell-checker:ignore openat TOCTOU CFLAGS set -e @@ -131,7 +131,7 @@ else # Disable useless checks "${SED}" -i 's|check-texinfo: $(syntax_checks)|check-texinfo:|' doc/local.mk ./bootstrap --skip-po - ./configure --quiet --disable-gcc-warnings --disable-nls --disable-dependency-tracking --disable-bold-man-page-references \ + CFLAGS="${CFLAGS} -pipe -O0 -s" ./configure --quiet --disable-gcc-warnings --disable-nls --disable-dependency-tracking --disable-bold-man-page-references \ "$([ "${SELINUX_ENABLED}" = 1 ] && echo --with-selinux || echo --without-selinux)" #Add timeout to to protect against hangs "${SED}" -i 's|^"\$@|'"${SYSTEM_TIMEOUT}"' 600 "\$@|' build-aux/test-driver From d08c04375e72fa0ed87740d613a5da32db5a3aa7 Mon Sep 17 00:00:00 2001 From: oech3 <> Date: Wed, 26 Nov 2025 10:38:11 +0900 Subject: [PATCH 2/2] Add a reason for CFLAGS --- util/build-gnu.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/util/build-gnu.sh b/util/build-gnu.sh index cc8e9d60823..1f9202fa1ed 100755 --- a/util/build-gnu.sh +++ b/util/build-gnu.sh @@ -131,6 +131,7 @@ else # Disable useless checks "${SED}" -i 's|check-texinfo: $(syntax_checks)|check-texinfo:|' doc/local.mk ./bootstrap --skip-po + # Use CFLAGS for best build time since we discard GNU coreutils CFLAGS="${CFLAGS} -pipe -O0 -s" ./configure --quiet --disable-gcc-warnings --disable-nls --disable-dependency-tracking --disable-bold-man-page-references \ "$([ "${SELINUX_ENABLED}" = 1 ] && echo --with-selinux || echo --without-selinux)" #Add timeout to to protect against hangs