From 781b32aa84eb9fb3092636beb3f6e4fee43add6c Mon Sep 17 00:00:00 2001 From: Thomas White Date: Wed, 30 May 2012 15:43:45 +0200 Subject: Reconfigure Gnulib with --libtool (and update to latest) --- m4/strndup.m4 | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) (limited to 'm4/strndup.m4') diff --git a/m4/strndup.m4 b/m4/strndup.m4 index d8f00cab..bdde5fe1 100644 --- a/m4/strndup.m4 +++ b/m4/strndup.m4 @@ -1,5 +1,5 @@ -# strndup.m4 serial 18 -dnl Copyright (C) 2002-2003, 2005-2011 Free Software Foundation, Inc. +# strndup.m4 serial 20 +dnl Copyright (C) 2002-2003, 2005-2012 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. @@ -18,13 +18,18 @@ AC_DEFUN([gl_FUNC_STRNDUP], fi if test $ac_cv_func_strndup = yes; then + HAVE_STRNDUP=1 # AIX 4.3.3, AIX 5.1 have a function that fails to add the terminating '\0'. AC_CACHE_CHECK([for working strndup], [gl_cv_func_strndup_works], [AC_RUN_IFELSE([ AC_LANG_PROGRAM([[#include #include ]], [[ #ifndef HAVE_DECL_STRNDUP - extern char *strndup (const char *, size_t); + extern + #ifdef __cplusplus + "C" + #endif + char *strndup (const char *, size_t); #endif char *s; s = strndup ("some longer string", 15); @@ -42,12 +47,9 @@ changequote(,)dnl changequote([,])dnl ])]) case $gl_cv_func_strndup_works in - *no) - REPLACE_STRNDUP=1 - AC_LIBOBJ([strndup]) - ;; + *no) REPLACE_STRNDUP=1 ;; esac else - AC_LIBOBJ([strndup]) + HAVE_STRNDUP=0 fi ]) -- cgit v1.2.3