From bf808ea0fc581f58ec4aabd9d7f24d3a5275bc7a Mon Sep 17 00:00:00 2001 From: Theo Buehler Date: Thu, 19 Dec 2024 20:24:33 +0100 Subject: Provide getdelim and getline compat shims These are portable implementations from NetBSD that are needed on Windows and perhaps some other platforms with the new versions of the mlkem tests. --- m4/check-libc.m4 | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'm4') diff --git a/m4/check-libc.m4 b/m4/check-libc.m4 index 40df15b..8cb849b 100644 --- a/m4/check-libc.m4 +++ b/m4/check-libc.m4 @@ -7,7 +7,7 @@ AC_CHECK_HEADERS([netinet/ip.h], [], [], ]) AC_HEADER_RESOLV # Check for general libc functions -AC_CHECK_FUNCS([asprintf freezero memmem]) +AC_CHECK_FUNCS([asprintf freezero getdelim getline memmem]) AC_CHECK_FUNCS([readpassphrase reallocarray recallocarray]) AC_CHECK_FUNCS([strcasecmp strlcat strlcpy strndup strnlen strsep strtonum]) AC_CHECK_FUNCS([timegm _mkgmtime timespecsub]) @@ -24,6 +24,8 @@ AC_CACHE_CHECK([for getpagesize], ac_cv_func_getpagesize, [ ]) AM_CONDITIONAL([HAVE_ASPRINTF], [test "x$ac_cv_func_asprintf" = xyes]) AM_CONDITIONAL([HAVE_FREEZERO], [test "x$ac_cv_func_freezero" = xyes]) +AM_CONDITIONAL([HAVE_GETDELIM], [test "x$ac_cv_func_getdelim" = xyes]) +AM_CONDITIONAL([HAVE_GETLINE], [test "x$ac_cv_func_getline" = xyes]) AM_CONDITIONAL([HAVE_GETPAGESIZE], [test "x$ac_cv_func_getpagesize" = xyes]) AM_CONDITIONAL([HAVE_GETOPT], [test "x$ac_cv_func_getopt" = xyes]) AM_CONDITIONAL([HAVE_MEMMEM], [test "x$ac_cv_func_memmem" = xyes]) -- cgit v1.2.3-55-g6feb