fchdir: Fix a compilation error on OS/2 kLIBC (regression 2023-09-29).
authorKO Myung-Hun <komh@chollian.net>
Mon, 2 Oct 2023 14:07:43 +0000 (23:07 +0900)
committerBruno Haible <bruno@clisp.org>
Mon, 2 Oct 2023 18:14:08 +0000 (20:14 +0200)
In fdopendir.c, GNULIB_defined_DIR requires REPLACE_FCHDIR to be defined.

* m4/fchdir.m4 (gl_FUNC_FCHDIR): Define REPLACE_FCHDIR macro to 1 if
REPLACE_FCHDIR is 1.

ChangeLog
m4/fchdir.m4

index 0472570f49f55995cc3e498179d08f06459d13a7..a8323ba86cf0e9b679cea89cea5615bff03a6bbb 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2023-10-02  KO Myung-Hun  <komh78@gmail.com>
+
+       fchdir: Fix a compilation error on OS/2 kLIBC (regression 2023-09-29).
+       * m4/fchdir.m4 (gl_FUNC_FCHDIR): Define REPLACE_FCHDIR macro to 1 if
+       REPLACE_FCHDIR is 1.
+
 2023-10-02  Bruno Haible  <bruno@clisp.org>
 
        totalorder, totalorderf, totalorderl: Fix some typos.
index ff92ceca2eed5713ee993da8d9bcd2793f7a4a3e..d160e49c8abf1b13c250aa7b57702232fcd66d66 100644 (file)
@@ -1,4 +1,4 @@
-# fchdir.m4 serial 31
+# fchdir.m4 serial 32
 dnl Copyright (C) 2006-2023 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
@@ -24,7 +24,7 @@ AC_DEFUN([gl_FUNC_FCHDIR],
     fi
   fi
 
-  if test $HAVE_FCHDIR = 0; then
+  if test $HAVE_FCHDIR = 0 || test $REPLACE_FCHDIR = 1; then
     AC_DEFINE([REPLACE_FCHDIR], [1],
       [Define to 1 if gnulib's fchdir() replacement is used.])
     dnl We must also replace anything that can manipulate a directory fd,