]> git.ipfire.org Git - thirdparty/gnulib.git/commitdiff
fcntl-h: Update platforms list re O_DIRECTORY.
authorBruno Haible <bruno@clisp.org>
Tue, 27 May 2025 09:24:45 +0000 (11:24 +0200)
committerBruno Haible <bruno@clisp.org>
Tue, 27 May 2025 09:29:10 +0000 (11:29 +0200)
* doc/posix-headers/fcntl.texi: Update platforms list.
* doc/posix-functions/open.texi: Likewise.
* doc/posix-functions/openat.texi: Likewise.
* m4/fcntl-o.m4 (gl_FCNTL_O_FLAGS): Guess that O_DIRECTORY works for
Mac OS X >= 10.5. Use prefix 'gl_', not 'ac_', for our variables.

ChangeLog
doc/posix-functions/open.texi
doc/posix-functions/openat.texi
doc/posix-headers/fcntl.texi
m4/fcntl-o.m4

index 446fbdc8f1f8926e08d008a2d416c96dfa4c00f1..380dda36d07fec10f37eb8b6a3818f68e5c1466c 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2025-05-27  Bruno Haible  <bruno@clisp.org>
+
+       fcntl-h: Update platforms list re O_DIRECTORY.
+       * doc/posix-headers/fcntl.texi: Update platforms list.
+       * doc/posix-functions/open.texi: Likewise.
+       * doc/posix-functions/openat.texi: Likewise.
+       * m4/fcntl-o.m4 (gl_FCNTL_O_FLAGS): Guess that O_DIRECTORY works for
+       Mac OS X >= 10.5. Use prefix 'gl_', not 'ac_', for our variables.
+
 2025-05-27  Bruno Haible  <bruno@clisp.org>
 
        doc: Style module name.
index 1f10f30ca915ffba4bb5370311f48e271ced0bd5..26bb757646d923b6956a1afe6a43773c727cb6c6 100644 (file)
@@ -16,8 +16,7 @@ Some platforms do not support @code{O_CLOEXEC}:
 Mac OS X 10.6, FreeBSD 8.4, NetBSD 5.1, OpenBSD 4.9, Minix 3.1.8, AIX 7.1, HP-UX 11, Solaris 10, Cygwin 1.7.x, mingw, MSVC 14.
 @item
 Some platforms do not support @code{O_DIRECTORY}:
-mingw, MSVC 14, glibc 2.0, OS X 10.9, FreeBSD 7.4, NetBSD 4.0.1, OpenBSD 4.9,
-AIX 7.1, HP-UX 11, Solaris 10.
+glibc 2.0, Mac OS X 10.4, FreeBSD 7.4, NetBSD 4.0.1, OpenBSD 4.9, HP-UX 11, Solaris 10, Cygwin 1.5.x, mingw, MSVC 14.
 @item
 On platforms where @code{off_t} is a 32-bit type, @code{open} may not work
 correctly with files 2 GiB and larger.  @xref{Large File Support}.
index 5c114dfe6d4110e0244ab6909eb220aabe3482af..8e39853629218d7583a568d4646ef97c277f5e68 100644 (file)
@@ -19,8 +19,7 @@ Some platforms do not support @code{O_CLOEXEC}:
 AIX 7.1, Solaris 10.
 @item
 Some platforms do not support @code{O_DIRECTORY}:
-mingw, MSVC 14, glibc 2.0, OS X 10.9, FreeBSD 7.4, NetBSD 4.0.1, OpenBSD 4.9,
-AIX 7.1, HP-UX 11, Solaris 10.
+glibc 2.0, Mac OS X 10.4, FreeBSD 7.4, NetBSD 4.0.1, OpenBSD 4.9, HP-UX 11, Solaris 10, Cygwin 1.5.x, mingw, MSVC 14.
 @item
 On platforms where @code{off_t} is a 32-bit type, @code{open} may not work
 correctly with files 2 GiB and larger.  @xref{Large File Support}.
index 22e791b5a86210321f2fd5cd88239e90c6ca42b3..d3ead0d3101e6e4ce694c3f7de404debbe38ffea 100644 (file)
@@ -93,8 +93,7 @@ which is generally safe.
 
 @item
 @samp{O_DIRECTORY} is not defined on some platforms:
-mingw, MSVC 14, glibc 2.0, OS X 10.9, FreeBSD 7.4, NetBSD 4.0.1, OpenBSD 4.9,
-AIX 7.1, HP-UX 11, Solaris 10.
+glibc 2.0, Mac OS X 10.4, FreeBSD 7.4, NetBSD 4.0.1, OpenBSD 4.9, HP-UX 11, Solaris 10, Cygwin 1.5.x, mingw, MSVC 14.
 
 @item
 @samp{FD_CLOEXEC}, @samp{F_DUPFD}, and @samp{F_GETFD} are not defined
index 2f0faebdd189c50c19f919daa6a1b2a2865ebfc6..9c19b582f8f81361667dbefcce96064e0d9d7012 100644 (file)
@@ -1,5 +1,5 @@
 # fcntl-o.m4
-# serial 9
+# serial 10
 dnl Copyright (C) 2006, 2009-2025 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
@@ -140,10 +140,9 @@ AC_DEFUN([gl_FCNTL_O_FLAGS],
        [AS_CASE([$host_os,$gl_cross_guess_normal],
           # The O_DIRECTORY test is known to fail on Mac OS X 10.4.11 (2007)
           # (see <https://bugs.gnu.org/78509#95>)
-          # and to succeed on macOS 12.6 [darwin21.6.0] (2021).
-          # For now, guess it fails on macOS 12.5 and earlier.
-          [darwin[[0-9]].*yes | darwin1[[0-9]]*.*yes | darwin20.*yes | \
-           darwin21.[[0-5]].*yes],
+          # and to succeed on Mac OS X 10.5.8 [darwin9.8.0] (2009).
+          # Guess it fails on Mac OS X 10.4.x and earlier.
+          [darwin[[0-8]].*yes],
              [gl_cv_header_working_fcntl_h="guessing no (bad O_DIRECTORY)"],
           # Known to be "no" on native MS-Windows.
           [mingw* | windows*],
@@ -151,17 +150,17 @@ AC_DEFUN([gl_FCNTL_O_FLAGS],
           [gl_cv_header_working_fcntl_h=$gl_cross_guess_normal])])])
 
   AS_CASE([$gl_cv_header_working_fcntl_h],
-    [*O_DIRECTORY* | *no], [ac_val=0], [ac_val=1])
-  AC_DEFINE_UNQUOTED([HAVE_WORKING_O_DIRECTORY], [$ac_val],
+    [*O_DIRECTORY* | *no], [gl_val=0], [gl_val=1])
+  AC_DEFINE_UNQUOTED([HAVE_WORKING_O_DIRECTORY], [$gl_val],
     [Define to 1 if O_DIRECTORY works, 0 otherwise.])
 
   AS_CASE([$gl_cv_header_working_fcntl_h],
-    [*O_NOATIME* | *no], [ac_val=0], [ac_val=1])
-  AC_DEFINE_UNQUOTED([HAVE_WORKING_O_NOATIME], [$ac_val],
+    [*O_NOATIME* | *no], [gl_val=0], [gl_val=1])
+  AC_DEFINE_UNQUOTED([HAVE_WORKING_O_NOATIME], [$gl_val],
     [Define to 1 if O_NOATIME works, 0 otherwise.])
 
   AS_CASE([$gl_cv_header_working_fcntl_h],
-    [*O_NOFOLLOW* | *no], [ac_val=0], [ac_val=1])
-  AC_DEFINE_UNQUOTED([HAVE_WORKING_O_NOFOLLOW], [$ac_val],
+    [*O_NOFOLLOW* | *no], [gl_val=0], [gl_val=1])
+  AC_DEFINE_UNQUOTED([HAVE_WORKING_O_NOFOLLOW], [$gl_val],
     [Define to 1 if O_NOFOLLOW works, 0 otherwise.])
 ])