[binutils-gdb] [gnulib] Skip 3rd-party m4 files in update-gnulib.sh
Tom de Vries
vries@sourceware.org
Mon Nov 16 20:43:11 GMT 2026
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=155b473af41b1556d285aa2e8326e0f13919d8e7
commit 155b473af41b1556d285aa2e8326e0f13919d8e7
Author: Tom de Vries <tdevries@suse.de>
Date: Mon Nov 16 21:43:06 2026 +0100
[gnulib] Skip 3rd-party m4 files in update-gnulib.sh
When running update-gnulib.sh, I get changes from
/usr/share/aclocal/po.m4, a file installed from package gettext-tools.
Fix this by running aclocal with:
- ACLOCAL_PATH="" and
- --system-acdir="<empty dir>".
After this change, running update-gnulib.sh produces no changes.
Approved-By: Simon Marchi <simon.marchi@efficios.com>
Diff:
---
gnulib/update-gnulib.sh | 16 +++++++++++++---
1 file changed, 13 insertions(+), 3 deletions(-)
diff --git a/gnulib/update-gnulib.sh b/gnulib/update-gnulib.sh
index f38b31f31fa..8203bf3a2ce 100755
--- a/gnulib/update-gnulib.sh
+++ b/gnulib/update-gnulib.sh
@@ -192,12 +192,22 @@ apply_patches ()
apply_patches "patches/0001-use-windows-stat"
apply_patches "patches/0002-no-solaris-_gl_attribute_dealloc"
-# Regenerate all necessary files...
-aclocal &&
+if ! empty_dir=$(mktemp -d); then
+ echo "Error: Failed to create empty dir. Aborting."
+ exit 1
+fi
+
+# Regenerate all necessary files. Run aclocal while ignoring 3rd-party .m4
+# files.
+ACLOCAL_PATH="" aclocal --system-acdir="$empty_dir" &&
autoconf &&
autoheader &&
automake
-if [ $? -ne 0 ]; then
+st=$?
+
+rmdir "$empty_dir"
+
+if [ $st -ne 0 ]; then
echo "Error: Failed to regenerate Makefiles and configure scripts."
exit 1
fi
More information about the Binutils-cvs
mailing list