2N/A# strnlen.m4 serial 12
2N/Adnl Copyright (C) 2002-2003, 2005-2007, 2009-2010 Free Software Foundation,
2N/Adnl Inc.
2N/Adnl This file is free software; the Free Software Foundation
2N/Adnl gives unlimited permission to copy and/or distribute it,
2N/Adnl with or without modifications, as long as this notice is preserved.
2N/A
2N/AAC_DEFUN([gl_FUNC_STRNLEN],
2N/A[
2N/A AC_REQUIRE([gl_HEADER_STRING_H_DEFAULTS])
2N/A
2N/A dnl Persuade glibc <string.h> to declare strnlen().
2N/A AC_REQUIRE([AC_USE_SYSTEM_EXTENSIONS])
2N/A
2N/A AC_CHECK_DECLS_ONCE([strnlen])
2N/A if test $ac_cv_have_decl_strnlen = no; then
2N/A HAVE_DECL_STRNLEN=0
2N/A else
2N/A AC_FUNC_STRNLEN
2N/A dnl Note: AC_FUNC_STRNLEN does AC_LIBOBJ([strnlen]).
2N/A if test $ac_cv_func_strnlen_working = no; then
2N/A REPLACE_STRNLEN=1
2N/A fi
2N/A fi
2N/A if test $HAVE_DECL_STRNLEN = 0 || test $REPLACE_STRNLEN = 1; then
2N/A AC_LIBOBJ([strnlen])
2N/A gl_PREREQ_STRNLEN
2N/A fi
2N/A])
2N/A
2N/A# Prerequisites of lib/strnlen.c.
2N/AAC_DEFUN([gl_PREREQ_STRNLEN], [:])