diff options
Diffstat (limited to 'm4/strstr.m4')
-rw-r--r-- | m4/strstr.m4 | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/m4/strstr.m4 b/m4/strstr.m4 index a2ec337f17..21d7768b04 100644 --- a/m4/strstr.m4 +++ b/m4/strstr.m4 @@ -1,5 +1,5 @@ -# strstr.m4 serial 21 -dnl Copyright (C) 2008-2020 Free Software Foundation, Inc. +# strstr.m4 serial 24 +dnl Copyright (C) 2008-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, dnl with or without modifications, as long as this notice is preserved. @@ -7,9 +7,9 @@ dnl with or without modifications, as long as this notice is preserved. dnl Check that strstr works. AC_DEFUN([gl_FUNC_STRSTR_SIMPLE], [ - AC_REQUIRE([gl_HEADER_STRING_H_DEFAULTS]) + AC_REQUIRE([gl_STRING_H_DEFAULTS]) AC_REQUIRE([gl_FUNC_MEMCHR]) - if test $HAVE_MEMCHR = 0 || test $REPLACE_MEMCHR = 1; then + if test $REPLACE_MEMCHR = 1; then REPLACE_STRSTR=1 else dnl Detect https://sourceware.org/bugzilla/show_bug.cgi?id=12092 @@ -18,7 +18,7 @@ AC_DEFUN([gl_FUNC_STRSTR_SIMPLE], [gl_cv_func_strstr_works_always], [AC_RUN_IFELSE( [AC_LANG_PROGRAM([[ -#include <string.h> /* for strstr */ +#include <string.h> /* for __GNU_LIBRARY__, strstr */ #ifdef __GNU_LIBRARY__ #include <features.h> #if __GLIBC__ == 2 && __GLIBC_MINOR__ == 28 @@ -40,6 +40,7 @@ AC_DEFUN([gl_FUNC_STRSTR_SIMPLE], dnl linear. AC_EGREP_CPP([Lucky user], [ +#include <string.h> /* for __GNU_LIBRARY__ */ #ifdef __GNU_LIBRARY__ #include <features.h> #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ > 12) || (__GLIBC__ > 2)) \ |