>From 64044f7934922d347c578fa8b2c5b2305aed5ca5 Mon Sep 17 00:00:00 2001 From: Bruno Haible Date: Thu, 19 Jan 2023 21:55:25 +0100 Subject: [PATCH 07/15] Fix warnings for functions introduced in Android API level 19. * m4/futimens.m4 (gl_FUNC_FUTIMENS): Test for futimens using gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE. * m4/utimens.m4 (gl_UTIMENS): Likewise. * m4/imaxabs.m4 (gl_FUNC_IMAXABS): Test for imaxabs using gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE. * m4/imaxdiv.m4 (gl_FUNC_IMAXDIV): Test for imaxdiv using gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE. --- ChangeLog | 11 +++++++++++ m4/futimens.m4 | 4 ++-- m4/imaxabs.m4 | 4 ++-- m4/imaxdiv.m4 | 4 ++-- m4/utimens.m4 | 5 +++-- 5 files changed, 20 insertions(+), 8 deletions(-) diff --git a/ChangeLog b/ChangeLog index 7d80045e81..33693bec9c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,14 @@ +2023-01-19 Bruno Haible + + Fix warnings for functions introduced in Android API level 19. + * m4/futimens.m4 (gl_FUNC_FUTIMENS): Test for futimens using + gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE. + * m4/utimens.m4 (gl_UTIMENS): Likewise. + * m4/imaxabs.m4 (gl_FUNC_IMAXABS): Test for imaxabs using + gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE. + * m4/imaxdiv.m4 (gl_FUNC_IMAXDIV): Test for imaxdiv using + gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE. + 2023-01-19 Bruno Haible Fix warnings for functions introduced in Android API level 18. diff --git a/m4/futimens.m4 b/m4/futimens.m4 index 3aaa10a0b5..8e997d6ea6 100644 --- a/m4/futimens.m4 +++ b/m4/futimens.m4 @@ -1,4 +1,4 @@ -# serial 9 +# serial 10 # See if we need to provide futimens replacement. dnl Copyright (C) 2009-2023 Free Software Foundation, Inc. @@ -13,7 +13,7 @@ AC_DEFUN([gl_FUNC_FUTIMENS], AC_REQUIRE([gl_SYS_STAT_H_DEFAULTS]) AC_REQUIRE([AC_CANONICAL_HOST]) dnl for cross-compiles AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS]) - AC_CHECK_FUNCS_ONCE([futimens]) + gl_CHECK_FUNCS_ANDROID([futimens], [[#include ]]) if test $ac_cv_func_futimens = no; then HAVE_FUTIMENS=0 else diff --git a/m4/imaxabs.m4 b/m4/imaxabs.m4 index 5fb2a6963f..504db4845c 100644 --- a/m4/imaxabs.m4 +++ b/m4/imaxabs.m4 @@ -1,4 +1,4 @@ -# imaxabs.m4 serial 4 +# imaxabs.m4 serial 5 dnl Copyright (C) 2006, 2009-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, @@ -9,7 +9,7 @@ AC_DEFUN([gl_FUNC_IMAXABS], AC_REQUIRE([gl_INTTYPES_H_DEFAULTS]) dnl On OSF/1 5.1 with cc, this function is declared but not defined. - AC_CHECK_FUNCS_ONCE([imaxabs]) + gl_CHECK_FUNCS_ANDROID([imaxabs], [[#include ]]) AC_CHECK_DECLS_ONCE([imaxabs]) if test "$ac_cv_have_decl_imaxabs" != yes; then HAVE_DECL_IMAXABS=0 diff --git a/m4/imaxdiv.m4 b/m4/imaxdiv.m4 index 65d2c65cbb..7ad5da4ebf 100644 --- a/m4/imaxdiv.m4 +++ b/m4/imaxdiv.m4 @@ -1,4 +1,4 @@ -# imaxdiv.m4 serial 5 +# imaxdiv.m4 serial 6 dnl Copyright (C) 2006, 2009-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, @@ -9,7 +9,7 @@ AC_DEFUN([gl_FUNC_IMAXDIV], AC_REQUIRE([gl_INTTYPES_H_DEFAULTS]) dnl On OSF/1 5.1 with cc, this function is declared but not defined. - AC_CHECK_FUNCS_ONCE([imaxdiv]) + gl_CHECK_FUNCS_ANDROID([imaxdiv], [[#include ]]) AC_CHECK_DECLS_ONCE([imaxdiv]) if test "$ac_cv_have_decl_imaxdiv" != yes; then HAVE_DECL_IMAXDIV=0 diff --git a/m4/utimens.m4 b/m4/utimens.m4 index 900b4f6aa3..ffd289e1c7 100644 --- a/m4/utimens.m4 +++ b/m4/utimens.m4 @@ -3,7 +3,7 @@ dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, dnl with or without modifications, as long as this notice is preserved. -dnl serial 13 +dnl serial 14 AC_DEFUN([gl_UTIMENS], [ @@ -11,9 +11,10 @@ AC_DEFUN([gl_UTIMENS], AC_REQUIRE([gl_FUNC_UTIMES]) AC_REQUIRE([gl_CHECK_TYPE_STRUCT_TIMESPEC]) AC_REQUIRE([AC_CANONICAL_HOST]) dnl for cross-compiles - AC_CHECK_FUNCS_ONCE([futimens lutimes]) + AC_CHECK_FUNCS_ONCE([lutimes]) gl_CHECK_FUNCS_ANDROID([futimes], [[#include ]]) gl_CHECK_FUNCS_ANDROID([futimesat], [[#include ]]) + gl_CHECK_FUNCS_ANDROID([futimens], [[#include ]]) gl_CHECK_FUNCS_ANDROID([utimensat], [[#include ]]) if test $ac_cv_func_futimens = no && test $ac_cv_func_futimesat = yes; then -- 2.34.1