Only in orig/usr/share/autoconf/autoconf: autoconf.m4f
diff -ur orig/usr/share/autoconf/autoconf/general.m4 /usr/share/autoconf/autoconf/general.m4
--- orig/usr/share/autoconf/autoconf/general.m4	2021-08-23 17:33:47.000000000 +0200
+++ /usr/share/autoconf/autoconf/general.m4	2022-06-08 22:06:17.918402371 +0200
@@ -2770,13 +2770,13 @@
 # come early, it is not included in AC_BEFORE checks.
 AC_DEFUN([AC_EGREP_CPP],
 [AC_LANG_PREPROC_REQUIRE()dnl
-AC_REQUIRE([AC_PROG_EGREP])dnl
+AC_REQUIRE([_AC_PROG_EGREP_TRADITIONAL])dnl
 AC_LANG_CONFTEST([AC_LANG_SOURCE([[$2]])])
 AS_IF([dnl eval is necessary to expand ac_cpp.
 dnl Ultrix and Pyramid sh refuse to redirect output of eval, so use subshell.
 (eval "$ac_cpp conftest.$ac_ext") 2>&AS_MESSAGE_LOG_FD |
 dnl Quote $1 to prevent m4 from eating character classes
-  $EGREP "[$1]" >/dev/null 2>&1],
+  $EGREP_TRADITIONAL "m4_bregexp([$1],[^[$-]],[.?])[$1]" >/dev/null 2>&1],
   [$3],
   [$4])
 rm -rf conftest*
diff -ur orig/usr/share/autoconf/autoconf/programs.m4 /usr/share/autoconf/autoconf/programs.m4
--- orig/usr/share/autoconf/autoconf/programs.m4	2021-08-23 17:33:47.000000000 +0200
+++ /usr/share/autoconf/autoconf/programs.m4	2022-06-08 23:29:37.710611417 +0200
@@ -365,6 +365,21 @@
  AC_SUBST([EGREP])
 ])# AC_PROG_EGREP
 
+# _AC_PROG_EGREP_TRADITIONAL
+# --------------------------
+# Check for a grep -E program or equivalent.
+# Less stringent than AC_PROG_EGREP, as it succeeds even if there
+# is no working 'grep' or if the -e option does not work (e.g., AT&T UnixPC).
+AC_DEFUN([_AC_PROG_EGREP_TRADITIONAL],
+[AC_CACHE_CHECK([for egrep -e], [ac_cv_path_EGREP_TRADITIONAL],
+   [_AC_PROG_GREP([EGREP_TRADITIONAL], [grep ggrep],
+      [-E 'EGR(EP|AC)_TRADITIONAL$'], [:])
+    AS_IF([test "$ac_cv_path_EGREP_TRADITIONAL"],
+      [ac_cv_path_EGREP_TRADITIONAL="$ac_cv_path_EGREP_TRADITIONAL -E"],
+      [_AC_PROG_GREP([EGREP_TRADITIONAL], [egrep],
+	 ['EGR(EP|AC)_TRADITIONAL$'])])])
+ EGREP_TRADITIONAL="$ac_cv_path_EGREP_TRADITIONAL"
+])
 
 # AC_PROG_FGREP
 # -------------
@@ -394,15 +409,16 @@
 ])
 
 
-# _AC_PROG_GREP(VARIABLE, PROGNAME-LIST, PROG-ARGUMENTS)
-# ------------------------------------------------------
+# _AC_PROG_GREP(VARIABLE, PROGNAME-LIST, [PROG-ARGUMENTS],
+# 		[ACTION-IF-NOT-FOUND])
+# --------------------------------------------------------
 # Solaris 9 /usr/xpg4/bin/*grep is suitable, but /usr/bin/*grep lacks -e.
 # AIX silently truncates long lines before matching.
 # NeXT understands only one -e and truncates long lines.
 m4_define([_AC_PROG_GREP],
 [_AC_PATH_PROGS_FEATURE_CHECK([$1], [$2],
 	[_AC_FEATURE_CHECK_LENGTH([ac_path_$1], [ac_cv_path_$1],
-		["$ac_path_$1" $3], [$1])], [],
+		["$ac_path_$1" $3], [$1])], [$4],
 	[$PATH$PATH_SEPARATOR/usr/xpg4/bin])dnl
 ])
 
Only in /usr/share/autoconf/autoconf: programs.m4.orig
