Control: tags -1 patch

On 2023-07-21 19:38:08 +0200, Vincent Lefevre wrote:
> Indeed, it's a bundled gnulib. I was surprised because there is
> no "gnulib" directory. Actually these are just files under the m4
> directory. The bug is in "m4/dirfd.m4". I can see
> 
>   if test $ac_cv_func_dirfd = no && test $gl_cv_func_dirfd_macro = no; then
>     HAVE_DIRFD=0
>   else
>     HAVE_DIRFD=1
>     dnl Replace only if the system declares dirfd already.
>     if test $ac_cv_have_decl_dirfd = yes; then
>       REPLACE_DIRFD=1
>     fi
> 
> where the last 4 lines
> 
>     dnl Replace only if the system declares dirfd already.
>     if test $ac_cv_have_decl_dirfd = yes; then
>       REPLACE_DIRFD=1
>     fi
> 
> need to be removed to match the upstream gnulib fix.

And I could check that the corresponding attached patch makes
the error disappear.

-- 
Vincent Lefèvre <vinc...@vinc17.net> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)
diff -Naurd grep-3.11-orig/m4/dirfd.m4 grep-3.11/m4/dirfd.m4
--- grep-3.11~/m4/dirfd.m4	2023-04-29 11:03:00.000000000 +0200
+++ grep-3.11/m4/dirfd.m4	2023-07-21 19:40:41.345044696 +0200
@@ -40,10 +40,6 @@
     HAVE_DIRFD=0
   else
     HAVE_DIRFD=1
-    dnl Replace only if the system declares dirfd already.
-    if test $ac_cv_have_decl_dirfd = yes; then
-      REPLACE_DIRFD=1
-    fi
     dnl Replace dirfd() on native Windows, to support fdopendir().
     AC_REQUIRE([gl_DIRENT_DIR])
     if test $DIR_HAS_FD_MEMBER = 0; then

Reply via email to