While the GCC compilefarm gives us access to a macOS 12 machine, GitHub actions give us access to all of macOS 11, 12, 13, 14. A continuous integration that I have set up [1] lists a test failure of test-mkfifoat on macOS 13 and 14.
With the combination of the 'abort-debug' and the CONTINUE_AFTER_ASSERT patches, I am able to get a reasonable stack trace of the failures of this test: FAIL: test-mkfifoat =================== ../../gltests/test-mkfifo.h:70: assertion 'func (BASE "link/", 0600) == -1' failed Stack trace: 0 test-mkfifoat 0x000000010803b91d _gl_pre_abort + 61 1 test-mkfifoat 0x000000010803b722 test_mkfifo + 1458 2 test-mkfifoat 0x000000010803a7d1 main + 49 3 dyld 0x00007ff80ad3f41f start + 1903 ../../gltests/test-mkfifo.h:70: assertion 'func (BASE "link/", 0600) == -1' failed Stack trace: 0 test-mkfifoat 0x000000010803b91d _gl_pre_abort + 61 1 test-mkfifoat 0x000000010803b722 test_mkfifo + 1458 2 test-mkfifoat 0x000000010803a7e1 main + 65 3 dyld 0x00007ff80ad3f41f start + 1903 ../../gltests/test-mkfifo.h:70: assertion 'func (BASE "link/", 0600) == -1' failed Stack trace: 0 test-mkfifoat 0x000000010803b91d _gl_pre_abort + 61 1 test-mkfifoat 0x000000010803b722 test_mkfifo + 1458 2 test-mkfifoat 0x000000010803a891 main + 241 3 dyld 0x00007ff80ad3f41f start + 1903 ../../gltests/test-mkfifo.h:70: assertion 'func (BASE "link/", 0600) == -1' failed Stack trace: 0 test-mkfifoat 0x000000010803b91d _gl_pre_abort + 61 1 test-mkfifoat 0x000000010803b722 test_mkfifo + 1458 2 test-mkfifoat 0x000000010803a8e5 main + 325 3 dyld 0x00007ff80ad3f41f start + 1903 FAIL test-mkfifoat (exit status: 1) The set of macOS versions corresponds to the platforms which have mkfifoat: $ grep mkfifoat logs-macos-*/log1 logs-macos-11/log1:checking whether mkfifoat is declared without a macro... no logs-macos-11/log1:checking for mkfifoat... no logs-macos-12/log1:checking whether mkfifoat is declared without a macro... yes logs-macos-12/log1:checking for mkfifoat... future OS version logs-macos-13/log1:checking whether mkfifoat is declared without a macro... yes logs-macos-13/log1:checking for mkfifoat... yes logs-macos-13/log1:checking whether mkfifoat rejects trailing slashes... yes logs-macos-14/log1:checking whether mkfifoat is declared without a macro... yes logs-macos-14/log1:checking for mkfifoat... yes logs-macos-14/log1:checking whether mkfifoat rejects trailing slashes... yes In other words, if it did not fail in previous macOS versions, it is because the mkfifoat system call was not present and Gnulib emulated it. Based on the above, I can only guess what the fix/workaround might be. I'm committing this. We'll see after the next CI run if it worked. [1] https://github.com/gnu-gnulib/ci-testdir-check/actions 2024-05-18 Bruno Haible <br...@clisp.org> mkfifoat: Work around a macOS 14 bug. * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Also test the case of a dangling symlink. * doc/posix-functions/mkfifoat.texi: Mention the macOS bug. diff --git a/doc/posix-functions/mkfifoat.texi b/doc/posix-functions/mkfifoat.texi index 15dce29927..298c2eaf02 100644 --- a/doc/posix-functions/mkfifoat.texi +++ b/doc/posix-functions/mkfifoat.texi @@ -16,6 +16,10 @@ This function does not fail when the file name argument ends in a slash and (without the slash) names a nonexistent file, on some platforms: AIX 7.2. +@item +This function does not fail when the file name argument ends in a slash +and (without the slash) names a symbolic link, on some platforms: +macOS 14. @end itemize Portability problems not fixed by Gnulib: diff --git a/m4/mkfifoat.m4 b/m4/mkfifoat.m4 index 9efffd58bb..763f870006 100644 --- a/m4/mkfifoat.m4 +++ b/m4/mkfifoat.m4 @@ -1,5 +1,5 @@ # mkfifoat.m4 -# serial 10 +# serial 11 dnl Copyright (C) 2009-2024 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, @@ -22,7 +22,7 @@ AC_DEFUN([gl_FUNC_MKFIFOAT] gl_CHECK_FUNCS_ANDROID_MACOS([mknodat], [[#include <sys/stat.h>]]) gl_CHECK_FUNCS_ANDROID_MACOS([mkfifoat], [[#include <sys/stat.h>]]) if test $ac_cv_func_mkfifoat = yes; then - dnl Check for AIX 7.2 bug with trailing slash. + dnl Check for AIX 7.2 bug and macOS 14 bugs with trailing slash. AC_CACHE_CHECK([whether mkfifoat rejects trailing slashes], [gl_cv_func_mkfifoat_works], [rm -f conftest.tmp @@ -30,10 +30,16 @@ AC_DEFUN([gl_FUNC_MKFIFOAT] [AC_LANG_PROGRAM( [[#include <fcntl.h> #include <sys/stat.h> + #include <unistd.h> ]], [[int result = 0; + /* This test fails on AIX 7.2. */ if (!mkfifoat (AT_FDCWD, "conftest.tmp/", 0600)) result |= 1; + /* This test fails on macOS 14. */ + if (!symlink ("conftest.fifo", "conftest.tmp") + && !mkfifoat (AT_FDCWD, "conftest.tmp/", 0600)) + result |= 2; return result; ]]) ], @@ -44,6 +50,8 @@ AC_DEFUN([gl_FUNC_MKFIFOAT] linux-* | linux) gl_cv_func_mkfifoat_works="guessing yes" ;; # Guess yes on glibc systems. *-gnu* | gnu*) gl_cv_func_mkfifoat_works="guessing yes" ;; + # Guess no on macOS systems. + darwin*) gl_cv_func_mkfifoat_works="guessing no" ;; # Guess no on AIX systems. aix*) gl_cv_func_mkfifoat_works="guessing no" ;; # If we don't know, obey --enable-cross-guesses.