>From 09730bf22348989d457861b85ffab15eb0f294cb Mon Sep 17 00:00:00 2001 From: Bruno Haible Date: Sun, 22 Jan 2023 12:30:17 +0100 Subject: [PATCH 24/47] Resolve conflicts for functions introduced in Android API level 21. * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Conditionally set REPLACE_MKNODAT. * lib/sys_stat.in.h (mknodat): Disable _GL_CXXALIASWARN invocation on non-glibc systems. --- ChangeLog | 4 ++++ lib/sys_stat.in.h | 2 ++ m4/mkfifoat.m4 | 5 ++++- 3 files changed, 10 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 092a3b50d5..33b820b888 100644 --- a/ChangeLog +++ b/ChangeLog @@ -2,6 +2,10 @@ Resolve conflicts for functions introduced in Android API level 21. + * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Conditionally set REPLACE_MKNODAT. + * lib/sys_stat.in.h (mknodat): Disable _GL_CXXALIASWARN invocation on + non-glibc systems. + * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Conditionally set REPLACE_STPNCPY. * lib/string.in.h (stpncpy): Disable _GL_CXXALIASWARN invocation on non-glibc systems. diff --git a/lib/sys_stat.in.h b/lib/sys_stat.in.h index 7d92239dd1..4ebe121a31 100644 --- a/lib/sys_stat.in.h +++ b/lib/sys_stat.in.h @@ -773,7 +773,9 @@ _GL_FUNCDECL_SYS (mknodat, int, _GL_CXXALIAS_SYS (mknodat, int, (int fd, char const *file, mode_t mode, dev_t dev)); # endif +# if __GLIBC__ >= 2 _GL_CXXALIASWARN (mknodat); +# endif #elif defined GNULIB_POSIXCHECK # undef mknodat # if HAVE_RAW_DECL_MKNODAT diff --git a/m4/mkfifoat.m4 b/m4/mkfifoat.m4 index e9ed962415..d7311f2557 100644 --- a/m4/mkfifoat.m4 +++ b/m4/mkfifoat.m4 @@ -1,4 +1,4 @@ -# serial 7 +# serial 8 # See if we need to provide mkfifoat/mknodat replacement. dnl Copyright (C) 2009-2023 Free Software Foundation, Inc. @@ -63,5 +63,8 @@ AC_DEFUN([gl_FUNC_MKFIFOAT], # No known system has mkfifoat but not mknodat HAVE_MKFIFOAT=0 HAVE_MKNODAT=0 + case "$gl_cv_onwards_func_mknodat" in + future*) REPLACE_MKNODAT=1 ;; + esac fi ]) -- 2.34.1