summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorP. J. McDermott <pj@pehjota.net>2023-10-05 10:29:09 (EDT)
committer P. J. McDermott <pj@pehjota.net>2023-10-05 11:08:15 (EDT)
commit92a875fc62f85fe8c8252b48b9c9d248715ddcc3 (patch)
tree5603d9b13eff863066a790c750d464afe45ececa
parent8b56edcda001038a7ed3e63dc44c545fc0b02227 (diff)
downloadatsign-92a875fc62f85fe8c8252b48b9c9d248715ddcc3.zip
atsign-92a875fc62f85fe8c8252b48b9c9d248715ddcc3.tar.gz
atsign-92a875fc62f85fe8c8252b48b9c9d248715ddcc3.tar.bz2
scripts/update-m4.sh: New script
-rwxr-xr-xscripts/update-m4.sh30
1 files changed, 30 insertions, 0 deletions
diff --git a/scripts/update-m4.sh b/scripts/update-m4.sh
new file mode 100755
index 0000000..e0d500d
--- /dev/null
+++ b/scripts/update-m4.sh
@@ -0,0 +1,30 @@
+#!/bin/sh
+#
+# Script to update M4 files from Gnulib, GNU Autoconf Archive, and GNU Coreutils
+#
+# Copyright (C) 2023 P. J. McDermott
+#
+# Copying and distribution of this file, with or without modification,
+# are permitted in any medium without royalty provided the copyright
+# notice and this notice are preserved. This file is offered as-is,
+# without any warranty.
+
+set -eu
+
+SV_CGIT='https://git.savannah.gnu.org/cgit'
+
+for f in m4/gl_*.m4; do
+ wget -O "${f}" "${SV_CGIT}/gnulib.git/plain/m4/${f#m4/gl_}"
+done
+
+for f in m4/ax_*.m4; do
+ wget -O "${f}" "${SV_CGIT}/autoconf-archive.git/plain/${f}"
+done
+
+wget -O - "${SV_CGIT}/coreutils.git/plain/configure.ac" | sed -n '
+ /^# Copyright /,/^dnl Written /{
+ p;
+ s/^dnl Written .*$//p;
+ };
+ /^# gl_GCC_VERSION_IFELSE/,/^$/p;
+ ' | sed '$d' 1>'m4/gcc_version.m4'