grep restricts its use of grep to things that are effectively fixed strings, in order to remove a recursive dependency on a "good" grep that supports arbitrarily long lines. However, mmap-anon.m4 has one such instance. This patch, suggested by Rainer Orth, removes "special" characters from the string being sought.

Ok?

Paolo

2011-06-27  Paolo Bonzini  <bonz...@gnu.org>

        * m4/mmap-anon.m4: Do not use special characters in the
        regular expression.
diff --git a/m4/mmap-anon.m4 b/m4/mmap-anon.m4
index 7ba7fd2..952536f 100644
--- a/m4/mmap-anon.m4
+++ b/m4/mmap-anon.m4
@@ -27,18 +27,18 @@ AC_DEFUN([gl_FUNC_MMAP_ANON],
   gl_have_mmap_anonymous=no
   if test $gl_have_mmap = yes; then
     AC_MSG_CHECKING([for MAP_ANONYMOUS])
-    AC_EGREP_CPP([I cant identify this map.], [
+    AC_EGREP_CPP([I cant identify this map], [
 #include <sys/mman.h>
 #ifdef MAP_ANONYMOUS
-    I cant identify this map.
+    I cant identify this map
 #endif
 ],
       [gl_have_mmap_anonymous=yes])
     if test $gl_have_mmap_anonymous != yes; then
-      AC_EGREP_CPP([I cant identify this map.], [
+      AC_EGREP_CPP([I cant identify this map], [
 #include <sys/mman.h>
 #ifdef MAP_ANON
-    I cant identify this map.
+    I cant identify this map
 #endif
 ],
         [AC_DEFINE([MAP_ANONYMOUS], [MAP_ANON],

Reply via email to