diff options
Diffstat (limited to 'gdb/gnulib/import/m4')
78 files changed, 1011 insertions, 273 deletions
diff --git a/gdb/gnulib/import/m4/00gnulib.m4 b/gdb/gnulib/import/m4/00gnulib.m4 index d978cb898cf..c7103ed52f5 100644 --- a/gdb/gnulib/import/m4/00gnulib.m4 +++ b/gdb/gnulib/import/m4/00gnulib.m4 @@ -1,12 +1,28 @@ -# 00gnulib.m4 serial 2 -dnl Copyright (C) 2009-2012 Free Software Foundation, Inc. +# 00gnulib.m4 serial 3 +dnl Copyright (C) 2009-2015 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. dnl This file must be named something that sorts before all other dnl gnulib-provided .m4 files. It is needed until such time as we can -dnl assume Autoconf 2.64, with its improved AC_DEFUN_ONCE semantics. +dnl assume Autoconf 2.64, with its improved AC_DEFUN_ONCE and +dnl m4_divert semantics. + +# Until autoconf 2.63, handling of the diversion stack required m4_init +# to be called first; but this does not happen with aclocal. Wrapping +# the entire execution in another layer of the diversion stack fixes this. +# Worse, prior to autoconf 2.62, m4_wrap depended on the underlying m4 +# for whether it was FIFO or LIFO; in order to properly balance with +# m4_init, we need to undo our push just before anything wrapped within +# the m4_init body. The way to ensure this is to wrap both sides of +# m4_init with a one-shot macro that does the pop at the right time. +m4_ifndef([_m4_divert_diversion], +[m4_divert_push([KILL]) +m4_define([gl_divert_fixup], [m4_divert_pop()m4_define([$0])]) +m4_define([m4_init], + [gl_divert_fixup()]m4_defn([m4_init])[gl_divert_fixup()])]) + # AC_DEFUN_ONCE([NAME], VALUE) # ---------------------------- diff --git a/gdb/gnulib/import/m4/absolute-header.m4 b/gdb/gnulib/import/m4/absolute-header.m4 new file mode 100644 index 00000000000..bc19dfc3010 --- /dev/null +++ b/gdb/gnulib/import/m4/absolute-header.m4 @@ -0,0 +1,102 @@ +# absolute-header.m4 serial 16 +dnl Copyright (C) 2006-2015 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. + +dnl From Derek Price. + +# gl_ABSOLUTE_HEADER(HEADER1 HEADER2 ...) +# --------------------------------------- +# Find the absolute name of a header file, testing first if the header exists. +# If the header were sys/inttypes.h, this macro would define +# ABSOLUTE_SYS_INTTYPES_H to the '""' quoted absolute name of sys/inttypes.h +# in config.h +# (e.g. '#define ABSOLUTE_SYS_INTTYPES_H "///usr/include/sys/inttypes.h"'). +# The three "///" are to pacify Sun C 5.8, which otherwise would say +# "warning: #include of /usr/include/... may be non-portable". +# Use '""', not '<>', so that the /// cannot be confused with a C99 comment. +# Note: This macro assumes that the header file is not empty after +# preprocessing, i.e. it does not only define preprocessor macros but also +# provides some type/enum definitions or function/variable declarations. +AC_DEFUN([gl_ABSOLUTE_HEADER], +[AC_REQUIRE([AC_CANONICAL_HOST]) +AC_LANG_PREPROC_REQUIRE()dnl +dnl FIXME: gl_absolute_header and ac_header_exists must be used unquoted +dnl until we can assume autoconf 2.64 or newer. +m4_foreach_w([gl_HEADER_NAME], [$1], + [AS_VAR_PUSHDEF([gl_absolute_header], + [gl_cv_absolute_]m4_defn([gl_HEADER_NAME]))dnl + AC_CACHE_CHECK([absolute name of <]m4_defn([gl_HEADER_NAME])[>], + m4_defn([gl_absolute_header]), + [AS_VAR_PUSHDEF([ac_header_exists], + [ac_cv_header_]m4_defn([gl_HEADER_NAME]))dnl + AC_CHECK_HEADERS_ONCE(m4_defn([gl_HEADER_NAME]))dnl + if test AS_VAR_GET(ac_header_exists) = yes; then + gl_ABSOLUTE_HEADER_ONE(m4_defn([gl_HEADER_NAME])) + fi + AS_VAR_POPDEF([ac_header_exists])dnl + ])dnl + AC_DEFINE_UNQUOTED(AS_TR_CPP([ABSOLUTE_]m4_defn([gl_HEADER_NAME])), + ["AS_VAR_GET(gl_absolute_header)"], + [Define this to an absolute name of <]m4_defn([gl_HEADER_NAME])[>.]) + AS_VAR_POPDEF([gl_absolute_header])dnl +])dnl +])# gl_ABSOLUTE_HEADER + +# gl_ABSOLUTE_HEADER_ONE(HEADER) +# ------------------------------ +# Like gl_ABSOLUTE_HEADER, except that: +# - it assumes that the header exists, +# - it uses the current CPPFLAGS, +# - it does not cache the result, +# - it is silent. +AC_DEFUN([gl_ABSOLUTE_HEADER_ONE], +[ + AC_REQUIRE([AC_CANONICAL_HOST]) + AC_LANG_CONFTEST([AC_LANG_SOURCE([[#include <]]m4_dquote([$1])[[>]])]) + dnl AIX "xlc -E" and "cc -E" omit #line directives for header files + dnl that contain only a #include of other header files and no + dnl non-comment tokens of their own. This leads to a failure to + dnl detect the absolute name of <dirent.h>, <signal.h>, <poll.h> + dnl and others. The workaround is to force preservation of comments + dnl through option -C. This ensures all necessary #line directives + dnl are present. GCC supports option -C as well. + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac +changequote(,) + case "$host_os" in + mingw*) + dnl For the sake of native Windows compilers (excluding gcc), + dnl treat backslash as a directory separator, like /. + dnl Actually, these compilers use a double-backslash as + dnl directory separator, inside the + dnl # line "filename" + dnl directives. + gl_dirsep_regex='[/\\]' + ;; + *) + gl_dirsep_regex='\/' + ;; + esac + dnl A sed expression that turns a string into a basic regular + dnl expression, for use within "/.../". + gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' + gl_header_literal_regex=`echo '$1' \ + | sed -e "$gl_make_literal_regex_sed"` + gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ + s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ + s|^/[^/]|//&| + p + q + }' +changequote([,]) + dnl eval is necessary to expand gl_absname_cpp. + dnl Ultrix and Pyramid sh refuse to redirect output of eval, + dnl so use subshell. + AS_VAR_SET([gl_cv_absolute_]AS_TR_SH([[$1]]), +[`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&AS_MESSAGE_LOG_FD | + sed -n "$gl_absolute_header_sed"`]) +]) diff --git a/gdb/gnulib/import/m4/alloca.m4 b/gdb/gnulib/import/m4/alloca.m4 index 656924be889..8408bed2882 100644 --- a/gdb/gnulib/import/m4/alloca.m4 +++ b/gdb/gnulib/import/m4/alloca.m4 @@ -1,5 +1,5 @@ # alloca.m4 serial 14 -dnl Copyright (C) 2002-2004, 2006-2007, 2009-2012 Free Software Foundation, +dnl Copyright (C) 2002-2004, 2006-2007, 2009-2015 Free Software Foundation, dnl Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, diff --git a/gdb/gnulib/import/m4/canonicalize.m4 b/gdb/gnulib/import/m4/canonicalize.m4 index ea51ac42031..6d932fd1ab6 100644 --- a/gdb/gnulib/import/m4/canonicalize.m4 +++ b/gdb/gnulib/import/m4/canonicalize.m4 @@ -1,6 +1,6 @@ # canonicalize.m4 serial 26 -dnl Copyright (C) 2003-2007, 2009-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2003-2007, 2009-2015 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, diff --git a/gdb/gnulib/import/m4/codeset.m4 b/gdb/gnulib/import/m4/codeset.m4 index cf53d241671..d7de8d67e0d 100644 --- a/gdb/gnulib/import/m4/codeset.m4 +++ b/gdb/gnulib/import/m4/codeset.m4 @@ -1,5 +1,5 @@ # codeset.m4 serial 5 (gettext-0.18.2) -dnl Copyright (C) 2000-2002, 2006, 2008-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2000-2002, 2006, 2008-2014 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. diff --git a/gdb/gnulib/import/m4/configmake.m4 b/gdb/gnulib/import/m4/configmake.m4 index 8c82371eb05..49d3a13e36b 100644 --- a/gdb/gnulib/import/m4/configmake.m4 +++ b/gdb/gnulib/import/m4/configmake.m4 @@ -1,5 +1,5 @@ -# configmake.m4 serial 1 -dnl Copyright (C) 2010-2012 Free Software Foundation, Inc. +# configmake.m4 serial 2 +dnl Copyright (C) 2010-2015 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,8 +7,9 @@ dnl with or without modifications, as long as this notice is preserved. # gl_CONFIGMAKE_PREP # ------------------ # Guarantee all of the standard directory variables, even when used with -# autoconf 2.59 (datarootdir wasn't supported until 2.59c) or automake -# 1.9.6 (pkglibexecdir wasn't supported until 1.10b.). +# autoconf 2.59 (datarootdir wasn't supported until 2.59c, and runstatedir +# in 2.70) or automake 1.9.6 (pkglibexecdir wasn't supported until 1.10b, +# and runstatedir in 1.14.1). AC_DEFUN([gl_CONFIGMAKE_PREP], [ dnl Technically, datadir should default to datarootdir. But if @@ -43,6 +44,10 @@ AC_DEFUN([gl_CONFIGMAKE_PREP], if test "x$localedir" = x; then AC_SUBST([localedir], ['${datarootdir}/locale']) fi + dnl Added in autoconf 2.70 + if test "x$runstatedir" = x; then + AC_SUBST([runstatedir], ['${localstatedir}/run']) + fi dnl Automake 1.9.6 only lacks pkglibexecdir; and since 1.11 merely dnl provides it without AC_SUBST, this blind use of AC_SUBST is safe. diff --git a/gdb/gnulib/import/m4/dirent_h.m4 b/gdb/gnulib/import/m4/dirent_h.m4 index f6c0fa7ba33..7abd1d05e19 100644 --- a/gdb/gnulib/import/m4/dirent_h.m4 +++ b/gdb/gnulib/import/m4/dirent_h.m4 @@ -1,5 +1,5 @@ # dirent_h.m4 serial 16 -dnl Copyright (C) 2008-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2008-2015 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. diff --git a/gdb/gnulib/import/m4/dirfd.m4 b/gdb/gnulib/import/m4/dirfd.m4 index fc475d78b9f..ce56cff6912 100644 --- a/gdb/gnulib/import/m4/dirfd.m4 +++ b/gdb/gnulib/import/m4/dirfd.m4 @@ -2,7 +2,7 @@ dnl Find out how to get the file descriptor associated with an open DIR*. -# Copyright (C) 2001-2006, 2008-2012 Free Software Foundation, Inc. +# Copyright (C) 2001-2006, 2008-2015 Free Software Foundation, Inc. # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. diff --git a/gdb/gnulib/import/m4/dirname.m4 b/gdb/gnulib/import/m4/dirname.m4 index 65639ec89e9..2a0be516e83 100644 --- a/gdb/gnulib/import/m4/dirname.m4 +++ b/gdb/gnulib/import/m4/dirname.m4 @@ -1,5 +1,5 @@ #serial 10 -*- autoconf -*- -dnl Copyright (C) 2002-2006, 2009-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2002-2006, 2009-2015 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. diff --git a/gdb/gnulib/import/m4/double-slash-root.m4 b/gdb/gnulib/import/m4/double-slash-root.m4 index 1e03751375b..f307eb2ffcf 100644 --- a/gdb/gnulib/import/m4/double-slash-root.m4 +++ b/gdb/gnulib/import/m4/double-slash-root.m4 @@ -1,5 +1,5 @@ # double-slash-root.m4 serial 4 -*- Autoconf -*- -dnl Copyright (C) 2006, 2008-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2006, 2008-2015 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. diff --git a/gdb/gnulib/import/m4/eealloc.m4 b/gdb/gnulib/import/m4/eealloc.m4 index 9e5df45d314..322bdd50b41 100644 --- a/gdb/gnulib/import/m4/eealloc.m4 +++ b/gdb/gnulib/import/m4/eealloc.m4 @@ -1,5 +1,5 @@ # eealloc.m4 serial 3 -dnl Copyright (C) 2003, 2009-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2003, 2009-2015 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. diff --git a/gdb/gnulib/import/m4/errno_h.m4 b/gdb/gnulib/import/m4/errno_h.m4 index 4e33ba853a3..cfaa6876153 100644 --- a/gdb/gnulib/import/m4/errno_h.m4 +++ b/gdb/gnulib/import/m4/errno_h.m4 @@ -1,5 +1,5 @@ # errno_h.m4 serial 12 -dnl Copyright (C) 2004, 2006, 2008-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2004, 2006, 2008-2015 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. diff --git a/gdb/gnulib/import/m4/exponentd.m4 b/gdb/gnulib/import/m4/exponentd.m4 index 0ae4ccfac93..84f1691a655 100644 --- a/gdb/gnulib/import/m4/exponentd.m4 +++ b/gdb/gnulib/import/m4/exponentd.m4 @@ -1,5 +1,5 @@ # exponentd.m4 serial 3 -dnl Copyright (C) 2007-2008, 2010-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2007-2008, 2010-2015 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. diff --git a/gdb/gnulib/import/m4/exponentl.m4 b/gdb/gnulib/import/m4/exponentl.m4 index a7cd13bc99f..6b95e737233 100644 --- a/gdb/gnulib/import/m4/exponentl.m4 +++ b/gdb/gnulib/import/m4/exponentl.m4 @@ -1,5 +1,5 @@ # exponentl.m4 serial 3 -dnl Copyright (C) 2007-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2007-2015 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. diff --git a/gdb/gnulib/import/m4/extensions.m4 b/gdb/gnulib/import/m4/extensions.m4 index 6d17d8a748b..35bc49c97bf 100644 --- a/gdb/gnulib/import/m4/extensions.m4 +++ b/gdb/gnulib/import/m4/extensions.m4 @@ -1,14 +1,14 @@ -# serial 12 -*- Autoconf -*- +# serial 13 -*- Autoconf -*- # Enable extensions on systems that normally disable them. -# Copyright (C) 2003, 2006-2012 Free Software Foundation, Inc. +# Copyright (C) 2003, 2006-2015 Free Software Foundation, Inc. # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# This definition of AC_USE_SYSTEM_EXTENSIONS is stolen from CVS +# This definition of AC_USE_SYSTEM_EXTENSIONS is stolen from git # Autoconf. Perhaps we can remove this once we can assume Autoconf -# 2.62 or later everywhere, but since CVS Autoconf mutates rapidly +# 2.70 or later everywhere, but since Autoconf mutates rapidly # enough in this area it's likely we'll need to redefine # AC_USE_SYSTEM_EXTENSIONS for quite some time. @@ -30,6 +30,7 @@ # ------------------------ # Enable extensions on systems that normally disable them, # typically due to standards-conformance issues. +# # Remember that #undef in AH_VERBATIM gets replaced with #define by # AC_DEFINE. The goal here is to define all known feature-enabling # macros, then, if reports of conflicts are made, disable macros that @@ -38,8 +39,6 @@ AC_DEFUN_ONCE([AC_USE_SYSTEM_EXTENSIONS], [AC_BEFORE([$0], [AC_COMPILE_IFELSE])dnl AC_BEFORE([$0], [AC_RUN_IFELSE])dnl - AC_REQUIRE([AC_CANONICAL_HOST]) - AC_CHECK_HEADER([minix/config.h], [MINIX=yes], [MINIX=]) if test "$MINIX" = yes; then AC_DEFINE([_POSIX_SOURCE], [1], @@ -50,24 +49,18 @@ AC_BEFORE([$0], [AC_RUN_IFELSE])dnl except with this defined.]) AC_DEFINE([_MINIX], [1], [Define to 1 if on MINIX.]) + AC_DEFINE([_NETBSD_SOURCE], [1], + [Define to 1 to make NetBSD features available. MINIX 3 needs this.]) fi - dnl HP-UX 11.11 defines mbstate_t only if _XOPEN_SOURCE is defined to 500, - dnl regardless of whether the flags -Ae or _D_HPUX_SOURCE=1 are already - dnl provided. - case "$host_os" in - hpux*) - AC_DEFINE([_XOPEN_SOURCE], [500], - [Define to 500 only on HP-UX.]) - ;; - esac - - AH_VERBATIM([__EXTENSIONS__], +dnl Use a different key than __EXTENSIONS__, as that name broke existing +dnl configure.ac when using autoheader 2.62. + AH_VERBATIM([USE_SYSTEM_EXTENSIONS], [/* Enable extensions on AIX 3, Interix. */ #ifndef _ALL_SOURCE # undef _ALL_SOURCE #endif -/* Enable general extensions on Mac OS X. */ +/* Enable general extensions on OS X. */ #ifndef _DARWIN_C_SOURCE # undef _DARWIN_C_SOURCE #endif @@ -75,6 +68,10 @@ AC_BEFORE([$0], [AC_RUN_IFELSE])dnl #ifndef _GNU_SOURCE # undef _GNU_SOURCE #endif +/* Use GNU style printf and scanf. */ +#ifndef __USE_MINGW_ANSI_STDIO +# undef __USE_MINGW_ANSI_STDIO +#endif /* Enable threading extensions on Solaris. */ #ifndef _POSIX_PTHREAD_SEMANTICS # undef _POSIX_PTHREAD_SEMANTICS @@ -83,6 +80,12 @@ AC_BEFORE([$0], [AC_RUN_IFELSE])dnl #ifndef _TANDEM_SOURCE # undef _TANDEM_SOURCE #endif +/* Enable X/Open extensions if necessary. HP-UX 11.11 defines + mbstate_t only if _XOPEN_SOURCE is defined to 500, regardless of + whether compiling with -Ae or -D_HPUX_SOURCE=1. */ +#ifndef _XOPEN_SOURCE +# undef _XOPEN_SOURCE +#endif /* Enable general extensions on Solaris. */ #ifndef __EXTENSIONS__ # undef __EXTENSIONS__ @@ -101,8 +104,25 @@ AC_BEFORE([$0], [AC_RUN_IFELSE])dnl AC_DEFINE([_ALL_SOURCE]) AC_DEFINE([_DARWIN_C_SOURCE]) AC_DEFINE([_GNU_SOURCE]) + AC_DEFINE([__USE_MINGW_ANSI_STDIO]) AC_DEFINE([_POSIX_PTHREAD_SEMANTICS]) AC_DEFINE([_TANDEM_SOURCE]) + AC_CACHE_CHECK([whether _XOPEN_SOURCE should be defined], + [ac_cv_should_define__xopen_source], + [ac_cv_should_define__xopen_source=no + AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM([[ + #include <wchar.h> + mbstate_t x;]])], + [], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM([[ + #define _XOPEN_SOURCE 500 + #include <wchar.h> + mbstate_t x;]])], + [ac_cv_should_define__xopen_source=yes])])]) + test $ac_cv_should_define__xopen_source = yes && + AC_DEFINE([_XOPEN_SOURCE], [500]) ])# AC_USE_SYSTEM_EXTENSIONS # gl_USE_SYSTEM_EXTENSIONS diff --git a/gdb/gnulib/import/m4/extern-inline.m4 b/gdb/gnulib/import/m4/extern-inline.m4 index 0a9fc9a75b6..72800650e6f 100644 --- a/gdb/gnulib/import/m4/extern-inline.m4 +++ b/gdb/gnulib/import/m4/extern-inline.m4 @@ -1,6 +1,6 @@ dnl 'extern inline' a la ISO C99. -dnl Copyright 2012 Free Software Foundation, Inc. +dnl Copyright 2012-2015 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. @@ -8,40 +8,79 @@ dnl with or without modifications, as long as this notice is preserved. AC_DEFUN([gl_EXTERN_INLINE], [ AH_VERBATIM([extern_inline], -[/* _GL_INLINE is a portable alternative to ISO C99 plain 'inline'. - _GL_EXTERN_INLINE is a portable alternative to 'extern inline'. - _GL_INLINE_HEADER_BEGIN contains useful stuff to put - in an include file, before uses of _GL_INLINE. - It suppresses GCC's bogus "no previous prototype for 'FOO'" diagnostic, - when FOO is an inline function in the header; see - <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54113>. - _GL_INLINE_HEADER_END contains useful stuff to put - in the same include file, after uses of _GL_INLINE. - - Suppress the use of extern inline on Apple's platforms, - as Libc-825.25 (2012-09-19) is incompatible with it; see - <http://lists.gnu.org/archive/html/bug-gnulib/2012-12/msg00023.html>. - Perhaps Apple will fix this some day. */ +[/* Please see the Gnulib manual for how to use these macros. + + Suppress extern inline with HP-UX cc, as it appears to be broken; see + <http://lists.gnu.org/archive/html/bug-texinfo/2013-02/msg00030.html>. + + Suppress extern inline with Sun C in standards-conformance mode, as it + mishandles inline functions that call each other. E.g., for 'inline void f + (void) { } inline void g (void) { f (); }', c99 incorrectly complains + 'reference to static identifier "f" in extern inline function'. + This bug was observed with Sun C 5.12 SunOS_i386 2011/11/16. + + Suppress extern inline (with or without __attribute__ ((__gnu_inline__))) + on configurations that mistakenly use 'static inline' to implement + functions or macros in standard C headers like <ctype.h>. For example, + if isdigit is mistakenly implemented via a static inline function, + a program containing an extern inline function that calls isdigit + may not work since the C standard prohibits extern inline functions + from calling static functions. This bug is known to occur on: + + OS X 10.8 and earlier; see: + http://lists.gnu.org/archive/html/bug-gnulib/2012-12/msg00023.html + + DragonFly; see + http://muscles.dragonflybsd.org/bulk/bleeding-edge-potential/latest-per-pkg/ah-tty-0.3.12.log + + FreeBSD; see: + http://lists.gnu.org/archive/html/bug-gnulib/2014-07/msg00104.html + + OS X 10.9 has a macro __header_inline indicating the bug is fixed for C and + for clang but remains for g++; see <http://trac.macports.org/ticket/41033>. + Assume DragonFly and FreeBSD will be similar. */ +#if (((defined __APPLE__ && defined __MACH__) \ + || defined __DragonFly__ || defined __FreeBSD__) \ + && (defined __header_inline \ + ? (defined __cplusplus && defined __GNUC_STDC_INLINE__ \ + && ! defined __clang__) \ + : ((! defined _DONT_USE_CTYPE_INLINE_ \ + && (defined __GNUC__ || defined __cplusplus)) \ + || (defined _FORTIFY_SOURCE && 0 < _FORTIFY_SOURCE \ + && defined __GNUC__ && ! defined __cplusplus)))) +# define _GL_EXTERN_INLINE_STDHEADER_BUG +#endif #if ((__GNUC__ \ ? defined __GNUC_STDC_INLINE__ && __GNUC_STDC_INLINE__ \ - : 199901L <= __STDC_VERSION__) \ - && !defined __APPLE__) + : (199901L <= __STDC_VERSION__ \ + && !defined __HP_cc \ + && !(defined __SUNPRO_C && __STDC__))) \ + && !defined _GL_EXTERN_INLINE_STDHEADER_BUG) # define _GL_INLINE inline # define _GL_EXTERN_INLINE extern inline -#elif 2 < __GNUC__ + (7 <= __GNUC_MINOR__) && !defined __APPLE__ -# if __GNUC_GNU_INLINE__ +# define _GL_EXTERN_INLINE_IN_USE +#elif (2 < __GNUC__ + (7 <= __GNUC_MINOR__) && !defined __STRICT_ANSI__ \ + && !defined _GL_EXTERN_INLINE_STDHEADER_BUG) +# if defined __GNUC_GNU_INLINE__ && __GNUC_GNU_INLINE__ /* __gnu_inline__ suppresses a GCC 4.2 diagnostic. */ # define _GL_INLINE extern inline __attribute__ ((__gnu_inline__)) # else # define _GL_INLINE extern inline # endif # define _GL_EXTERN_INLINE extern +# define _GL_EXTERN_INLINE_IN_USE #else # define _GL_INLINE static _GL_UNUSED # define _GL_EXTERN_INLINE static _GL_UNUSED #endif -#if 4 < __GNUC__ + (6 <= __GNUC_MINOR__) +/* In GCC 4.6 (inclusive) to 5.1 (exclusive), + suppress bogus "no previous prototype for 'FOO'" + and "no previous declaration for 'FOO'" diagnostics, + when FOO is an inline function in the header; see + <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=54113> and + <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63877>. */ +#if __GNUC__ == 4 && 6 <= __GNUC_MINOR__ # if defined __GNUC_STDC_INLINE__ && __GNUC_STDC_INLINE__ # define _GL_INLINE_HEADER_CONST_PRAGMA # else diff --git a/gdb/gnulib/import/m4/fcntl-o.m4 b/gdb/gnulib/import/m4/fcntl-o.m4 index 740e78b6819..891a62fb6a3 100644 --- a/gdb/gnulib/import/m4/fcntl-o.m4 +++ b/gdb/gnulib/import/m4/fcntl-o.m4 @@ -1,5 +1,5 @@ # fcntl-o.m4 serial 4 -dnl Copyright (C) 2006, 2009-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2006, 2009-2015 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. diff --git a/gdb/gnulib/import/m4/float_h.m4 b/gdb/gnulib/import/m4/float_h.m4 index 51c9c7b35c7..e4853f3b091 100644 --- a/gdb/gnulib/import/m4/float_h.m4 +++ b/gdb/gnulib/import/m4/float_h.m4 @@ -1,5 +1,5 @@ # float_h.m4 serial 9 -dnl Copyright (C) 2007, 2009-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2007, 2009-2015 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. diff --git a/gdb/gnulib/import/m4/fnmatch.m4 b/gdb/gnulib/import/m4/fnmatch.m4 index e46b6e521cf..c33792fe956 100644 --- a/gdb/gnulib/import/m4/fnmatch.m4 +++ b/gdb/gnulib/import/m4/fnmatch.m4 @@ -1,6 +1,6 @@ # Check for fnmatch - serial 9. -# Copyright (C) 2000-2007, 2009-2012 Free Software Foundation, Inc. +# Copyright (C) 2000-2007, 2009-2015 Free Software Foundation, Inc. # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. diff --git a/gdb/gnulib/import/m4/fpieee.m4 b/gdb/gnulib/import/m4/fpieee.m4 index 82fd778325b..a4e48997ed9 100644 --- a/gdb/gnulib/import/m4/fpieee.m4 +++ b/gdb/gnulib/import/m4/fpieee.m4 @@ -1,5 +1,5 @@ # fpieee.m4 serial 2 -dnl Copyright (C) 2007, 2009-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2007, 2009-2015 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. diff --git a/gdb/gnulib/import/m4/frexp.m4 b/gdb/gnulib/import/m4/frexp.m4 index fb8db7046e6..04f40679a63 100644 --- a/gdb/gnulib/import/m4/frexp.m4 +++ b/gdb/gnulib/import/m4/frexp.m4 @@ -1,5 +1,5 @@ -# frexp.m4 serial 14 -dnl Copyright (C) 2007-2012 Free Software Foundation, Inc. +# frexp.m4 serial 15 +dnl Copyright (C) 2007-2015 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. @@ -93,7 +93,7 @@ AC_DEFUN([gl_FUNC_FREXP_WORKS], [ AC_REQUIRE([AC_PROG_CC]) AC_REQUIRE([AC_CANONICAL_HOST]) dnl for cross-compiles - AC_CHECK_FUNCS_ONCE([alarm]) + AC_CHECK_DECLS_ONCE([alarm]) AC_CACHE_CHECK([whether frexp works], [gl_cv_func_frexp_works], [ AC_RUN_IFELSE( @@ -101,7 +101,8 @@ AC_DEFUN([gl_FUNC_FREXP_WORKS], #include <float.h> #include <math.h> #include <string.h> -#if HAVE_ALARM +#if HAVE_DECL_ALARM +# include <signal.h> # include <unistd.h> #endif /* HP cc on HP-UX 10.20 has a bug with the constant expression -0.0. @@ -124,9 +125,10 @@ int main() int i; volatile double x; double zero = 0.0; -#if HAVE_ALARM +#if HAVE_DECL_ALARM /* NeXTstep 3.3 frexp() runs into an endless loop when called on an infinite number. Let the test fail in this case. */ + signal (SIGALRM, SIG_DFL); alarm (5); #endif /* Test on denormalized numbers. */ diff --git a/gdb/gnulib/import/m4/frexpl.m4 b/gdb/gnulib/import/m4/frexpl.m4 index 774d540fd9c..cd3ac6e52e8 100644 --- a/gdb/gnulib/import/m4/frexpl.m4 +++ b/gdb/gnulib/import/m4/frexpl.m4 @@ -1,5 +1,5 @@ # frexpl.m4 serial 20 -dnl Copyright (C) 2007-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2007-2015 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. diff --git a/gdb/gnulib/import/m4/gettimeofday.m4 b/gdb/gnulib/import/m4/gettimeofday.m4 new file mode 100644 index 00000000000..ce246e18bc2 --- /dev/null +++ b/gdb/gnulib/import/m4/gettimeofday.m4 @@ -0,0 +1,138 @@ +# serial 21 + +# Copyright (C) 2001-2003, 2005, 2007, 2009-2015 Free Software Foundation, Inc. +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +dnl From Jim Meyering. + +AC_DEFUN([gl_FUNC_GETTIMEOFDAY], +[ + AC_REQUIRE([AC_C_RESTRICT]) + AC_REQUIRE([gl_HEADER_SYS_TIME_H]) + AC_REQUIRE([gl_HEADER_SYS_TIME_H_DEFAULTS]) + AC_CHECK_FUNCS_ONCE([gettimeofday]) + + gl_gettimeofday_timezone=void + if test $ac_cv_func_gettimeofday != yes; then + HAVE_GETTIMEOFDAY=0 + else + gl_FUNC_GETTIMEOFDAY_CLOBBER + AC_CACHE_CHECK([for gettimeofday with POSIX signature], + [gl_cv_func_gettimeofday_posix_signature], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM( + [[#include <sys/time.h> + struct timeval c; + int gettimeofday (struct timeval *restrict, void *restrict); + ]], + [[/* glibc uses struct timezone * rather than the POSIX void * + if _GNU_SOURCE is defined. However, since the only portable + use of gettimeofday uses NULL as the second parameter, and + since the glibc definition is actually more typesafe, it is + not worth wrapping this to get a compliant signature. */ + int (*f) (struct timeval *restrict, void *restrict) + = gettimeofday; + int x = f (&c, 0); + return !(x | c.tv_sec | c.tv_usec); + ]])], + [gl_cv_func_gettimeofday_posix_signature=yes], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM( + [[#include <sys/time.h> +int gettimeofday (struct timeval *restrict, struct timezone *restrict); + ]])], + [gl_cv_func_gettimeofday_posix_signature=almost], + [gl_cv_func_gettimeofday_posix_signature=no])])]) + if test $gl_cv_func_gettimeofday_posix_signature = almost; then + gl_gettimeofday_timezone='struct timezone' + elif test $gl_cv_func_gettimeofday_posix_signature != yes; then + REPLACE_GETTIMEOFDAY=1 + fi + dnl If we override 'struct timeval', we also have to override gettimeofday. + if test $REPLACE_STRUCT_TIMEVAL = 1; then + REPLACE_GETTIMEOFDAY=1 + fi + m4_ifdef([gl_FUNC_TZSET_CLOBBER], [ + gl_FUNC_TZSET_CLOBBER + case "$gl_cv_func_tzset_clobber" in + *yes) + REPLACE_GETTIMEOFDAY=1 + gl_GETTIMEOFDAY_REPLACE_LOCALTIME + AC_DEFINE([tzset], [rpl_tzset], + [Define to rpl_tzset if the wrapper function should be used.]) + AC_DEFINE([TZSET_CLOBBERS_LOCALTIME], [1], + [Define if tzset clobbers localtime's static buffer.]) + ;; + esac + ]) + fi + AC_DEFINE_UNQUOTED([GETTIMEOFDAY_TIMEZONE], [$gl_gettimeofday_timezone], + [Define this to 'void' or 'struct timezone' to match the system's + declaration of the second argument to gettimeofday.]) +]) + + +dnl See if gettimeofday clobbers the static buffer that localtime uses +dnl for its return value. The gettimeofday function from Mac OS X 10.0.4 +dnl (i.e., Darwin 1.3.7) has this problem. +dnl +dnl If it does, then arrange to use gettimeofday and localtime only via +dnl the wrapper functions that work around the problem. + +AC_DEFUN([gl_FUNC_GETTIMEOFDAY_CLOBBER], +[ + AC_REQUIRE([gl_HEADER_SYS_TIME_H]) + AC_REQUIRE([AC_CANONICAL_HOST]) dnl for cross-compiles + + AC_CACHE_CHECK([whether gettimeofday clobbers localtime buffer], + [gl_cv_func_gettimeofday_clobber], + [AC_RUN_IFELSE( + [AC_LANG_PROGRAM( + [[#include <string.h> + #include <sys/time.h> + #include <time.h> + #include <stdlib.h> + ]], + [[ + time_t t = 0; + struct tm *lt; + struct tm saved_lt; + struct timeval tv; + lt = localtime (&t); + saved_lt = *lt; + gettimeofday (&tv, NULL); + return memcmp (lt, &saved_lt, sizeof (struct tm)) != 0; + ]])], + [gl_cv_func_gettimeofday_clobber=no], + [gl_cv_func_gettimeofday_clobber=yes], + [# When cross-compiling: + case "$host_os" in + # Guess all is fine on glibc systems. + *-gnu*) gl_cv_func_gettimeofday_clobber="guessing no" ;; + # If we don't know, assume the worst. + *) gl_cv_func_gettimeofday_clobber="guessing yes" ;; + esac + ])]) + + case "$gl_cv_func_gettimeofday_clobber" in + *yes) + REPLACE_GETTIMEOFDAY=1 + gl_GETTIMEOFDAY_REPLACE_LOCALTIME + AC_DEFINE([GETTIMEOFDAY_CLOBBERS_LOCALTIME], [1], + [Define if gettimeofday clobbers the localtime buffer.]) + ;; + esac +]) + +AC_DEFUN([gl_GETTIMEOFDAY_REPLACE_LOCALTIME], [ + REPLACE_GMTIME=1 + REPLACE_LOCALTIME=1 +]) + +# Prerequisites of lib/gettimeofday.c. +AC_DEFUN([gl_PREREQ_GETTIMEOFDAY], [ + AC_CHECK_HEADERS([sys/timeb.h]) + AC_CHECK_FUNCS([_ftime]) +]) diff --git a/gdb/gnulib/import/m4/glibc21.m4 b/gdb/gnulib/import/m4/glibc21.m4 index c938fb1a0c3..3a971c5a240 100644 --- a/gdb/gnulib/import/m4/glibc21.m4 +++ b/gdb/gnulib/import/m4/glibc21.m4 @@ -1,5 +1,5 @@ # glibc21.m4 serial 5 -dnl Copyright (C) 2000-2002, 2004, 2008, 2010-2012 Free Software Foundation, +dnl Copyright (C) 2000-2002, 2004, 2008, 2010-2015 Free Software Foundation, dnl Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, diff --git a/gdb/gnulib/import/m4/gnulib-cache.m4 b/gdb/gnulib/import/m4/gnulib-cache.m4 index 959cdb68933..ad51e3e7d68 100644 --- a/gdb/gnulib/import/m4/gnulib-cache.m4 +++ b/gdb/gnulib/import/m4/gnulib-cache.m4 @@ -1,4 +1,4 @@ -# Copyright (C) 2002-2012 Free Software Foundation, Inc. +# Copyright (C) 2002-2015 Free Software Foundation, Inc. # # This file is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by diff --git a/gdb/gnulib/import/m4/gnulib-common.m4 b/gdb/gnulib/import/m4/gnulib-common.m4 index 15d2b2b3dea..40e82f6e27f 100644 --- a/gdb/gnulib/import/m4/gnulib-common.m4 +++ b/gdb/gnulib/import/m4/gnulib-common.m4 @@ -1,5 +1,5 @@ -# gnulib-common.m4 serial 33 -dnl Copyright (C) 2007-2012 Free Software Foundation, Inc. +# gnulib-common.m4 serial 36 +dnl Copyright (C) 2007-2015 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. @@ -49,6 +49,16 @@ AC_DEFUN([gl_COMMON_BODY], [ is a misnomer outside of parameter lists. */ #define _UNUSED_PARAMETER_ _GL_UNUSED +/* gcc supports the "unused" attribute on possibly unused labels, and + g++ has since version 4.5. Note to support C++ as well as C, + _GL_UNUSED_LABEL should be used with a trailing ; */ +#if !defined __cplusplus || __GNUC__ > 4 \ + || (__GNUC__ == 4 && __GNUC_MINOR__ >= 5) +# define _GL_UNUSED_LABEL _GL_UNUSED +#else +# define _GL_UNUSED_LABEL +#endif + /* The __pure__ attribute was added in gcc 2.96. */ #if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 96) # define _GL_ATTRIBUTE_PURE __attribute__ ((__pure__)) @@ -268,12 +278,12 @@ Amsterdam dnl but prefer ${host}-ar over ar (useful for cross-compiling). AC_CHECK_TOOL([AR], [ar], [ar]) if test -z "$ARFLAGS"; then - ARFLAGS='cru' + ARFLAGS='cr' fi fi else if test -z "$ARFLAGS"; then - ARFLAGS='cru' + ARFLAGS='cr' fi fi AC_SUBST([AR]) @@ -294,6 +304,8 @@ Amsterdam # for interoperability with automake-1.9.6 from autoconf-2.62. # Remove this macro when we can assume autoconf >= 2.62 or # autoconf >= 2.60 && automake >= 1.10. +# AC_AUTOCONF_VERSION was introduced in 2.62, so use that as the witness. +m4_ifndef([AC_AUTOCONF_VERSION],[ m4_ifdef([AC_PROG_MKDIR_P], [ dnl For automake-1.9.6 && autoconf < 2.62: Ensure MKDIR_P is AC_SUBSTed. m4_define([AC_PROG_MKDIR_P], @@ -304,27 +316,31 @@ m4_ifdef([AC_PROG_MKDIR_P], [ [AC_REQUIRE([AM_PROG_MKDIR_P])dnl defined by automake MKDIR_P='$(mkdir_p)' AC_SUBST([MKDIR_P])])]) +]) # AC_C_RESTRICT -# This definition overrides the AC_C_RESTRICT macro from autoconf 2.60..2.61, -# so that mixed use of GNU C and GNU C++ and mixed use of Sun C and Sun C++ -# works. -# This definition can be removed once autoconf >= 2.62 can be assumed. -m4_if(m4_version_compare(m4_defn([m4_PACKAGE_VERSION]),[2.62]),[-1],[ +# This definition is copied from post-2.69 Autoconf and overrides the +# AC_C_RESTRICT macro from autoconf 2.60..2.69. It can be removed +# once autoconf >= 2.70 can be assumed. It's painful to check version +# numbers, and in practice this macro is more up-to-date than Autoconf +# is, so override Autoconf unconditionally. AC_DEFUN([AC_C_RESTRICT], [AC_CACHE_CHECK([for C/C++ restrict keyword], [ac_cv_c_restrict], [ac_cv_c_restrict=no # The order here caters to the fact that C++ does not require restrict. for ac_kw in __restrict __restrict__ _Restrict restrict; do - AC_COMPILE_IFELSE([AC_LANG_PROGRAM( - [[typedef int * int_ptr; - int foo (int_ptr $ac_kw ip) { - return ip[0]; - }]], - [[int s[1]; - int * $ac_kw t = s; - t[0] = 0; - return foo(t)]])], + AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM( + [[typedef int *int_ptr; + int foo (int_ptr $ac_kw ip) { return ip[0]; } + int bar (int [$ac_kw]); /* Catch GCC bug 14050. */ + int bar (int ip[$ac_kw]) { return ip[0]; } + ]], + [[int s[1]; + int *$ac_kw t = s; + t[0] = 0; + return foo (t) + bar (t); + ]])], [ac_cv_c_restrict=$ac_kw]) test "$ac_cv_c_restrict" != no && break done @@ -334,21 +350,21 @@ AC_DEFUN([AC_C_RESTRICT], nothing if this is not supported. Do not define if restrict is supported directly. */ #undef restrict -/* Work around a bug in Sun C++: it does not support _Restrict, even - though the corresponding Sun C compiler does, which causes - "#define restrict _Restrict" in the previous line. Perhaps some future - version of Sun C++ will work with _Restrict; if so, it'll probably - define __RESTRICT, just as Sun C does. */ +/* Work around a bug in Sun C++: it does not support _Restrict or + __restrict__, even though the corresponding Sun C compiler ends up with + "#define restrict _Restrict" or "#define restrict __restrict__" in the + previous line. Perhaps some future version of Sun C++ will work with + restrict; if so, hopefully it defines __RESTRICT like Sun C does. */ #if defined __SUNPRO_CC && !defined __RESTRICT # define _Restrict +# define __restrict__ #endif]) case $ac_cv_c_restrict in restrict) ;; no) AC_DEFINE([restrict], []) ;; *) AC_DEFINE_UNQUOTED([restrict], [$ac_cv_c_restrict]) ;; esac -]) -]) +])# AC_C_RESTRICT # gl_BIGENDIAN # is like AC_C_BIGENDIAN, except that it can be AC_REQUIREd. @@ -371,3 +387,63 @@ AC_DEFUN([gl_CACHE_VAL_SILENT], AC_CACHE_VAL([$1], [$2]) as_echo_n="$saved_as_echo_n" ]) + +# AS_VAR_COPY was added in autoconf 2.63b +m4_define_default([AS_VAR_COPY], +[AS_LITERAL_IF([$1[]$2], [$1=$$2], [eval $1=\$$2])]) + +# AC_PROG_SED was added in autoconf 2.59b +m4_ifndef([AC_PROG_SED], +[AC_DEFUN([AC_PROG_SED], +[AC_CACHE_CHECK([for a sed that does not truncate output], ac_cv_path_SED, + [dnl ac_script should not contain more than 99 commands (for HP-UX sed), + dnl but more than about 7000 bytes, to catch a limit in Solaris 8 /usr/ucb/sed. + ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ + for ac_i in 1 2 3 4 5 6 7; do + ac_script="$ac_script$as_nl$ac_script" + done + echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed + AS_UNSET([ac_script]) + if test -z "$SED"; then + ac_path_SED_found=false + _AS_PATH_WALK([], [ + for ac_prog in sed gsed; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" + AS_EXECUTABLE_P(["$ac_path_SED"]) || continue + case `"$ac_path_SED" --version 2>&1` in + *GNU*) ac_cv_path_SED=$ac_path_SED ac_path_SED_found=:;; + *) + ac_count=0 + _AS_ECHO_N([0123456789]) >conftest.in + while : + do + cat conftest.in conftest.in >conftest.tmp + mv conftest.tmp conftest.in + cp conftest.in conftest.nl + echo >> conftest.nl + "$ac_path_SED" -f conftest.sed <conftest.nl >conftest.out 2>/dev/null || break + diff conftest.out conftest.nl >/dev/null 2>&1 || break + ac_count=`expr $ac_count + 1` + if test $ac_count -gt ${ac_path_SED_max-0}; then + # Best so far, but keep looking for better + ac_cv_path_SED=$ac_path_SED + ac_path_SED_max=$ac_count + fi + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; + esac + $ac_path_SED_found && break 3 + done + done]) + if test -z "$ac_cv_path_SED"; then + AC_ERROR([no acceptable sed could be found in \$PATH]) + fi + else + ac_cv_path_SED=$SED + fi + SED="$ac_cv_path_SED" + AC_SUBST([SED])dnl + rm -f conftest.sed +])])]) diff --git a/gdb/gnulib/import/m4/gnulib-comp.m4 b/gdb/gnulib/import/m4/gnulib-comp.m4 index 29f8f7332c2..5601894f5b1 100644 --- a/gdb/gnulib/import/m4/gnulib-comp.m4 +++ b/gdb/gnulib/import/m4/gnulib-comp.m4 @@ -1,5 +1,5 @@ # DO NOT EDIT! GENERATED AUTOMATICALLY! -# Copyright (C) 2002-2012 Free Software Foundation, Inc. +# Copyright (C) 2002-2015 Free Software Foundation, Inc. # # This file is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -38,6 +38,7 @@ AC_DEFUN([gl_EARLY], m4_pattern_allow([^gl_LIBOBJS$])dnl a variable m4_pattern_allow([^gl_LTLIBOBJS$])dnl a variable AC_REQUIRE([gl_PROG_AR_RANLIB]) + # Code from module absolute-header: # Code from module alloca: # Code from module alloca-opt: # Code from module canonicalize-lgpl: @@ -60,6 +61,7 @@ AC_DEFUN([gl_EARLY], # Code from module fpucw: # Code from module frexp: # Code from module frexpl: + # Code from module gettimeofday: # Code from module include_next: # Code from module inttypes: # Code from module inttypes-incomplete: @@ -103,6 +105,7 @@ AC_DEFUN([gl_EARLY], # Code from module strstr-simple: # Code from module strtok_r: # Code from module sys_stat: + # Code from module sys_time: # Code from module sys_types: # Code from module time: # Code from module unistd: @@ -176,6 +179,12 @@ AC_DEFUN([gl_INIT], AC_LIBOBJ([frexpl]) fi gl_MATH_MODULE_INDICATOR([frexpl]) + gl_FUNC_GETTIMEOFDAY + if test $HAVE_GETTIMEOFDAY = 0 || test $REPLACE_GETTIMEOFDAY = 1; then + AC_LIBOBJ([gettimeofday]) + gl_PREREQ_GETTIMEOFDAY + fi + gl_SYS_TIME_MODULE_INDICATOR([gettimeofday]) gl_INTTYPES_H gl_INTTYPES_INCOMPLETE gl_FUNC_ISNAND_NO_LIBM @@ -287,6 +296,8 @@ AC_DEFUN([gl_INIT], gl_STRING_MODULE_INDICATOR([strtok_r]) gl_HEADER_SYS_STAT_H AC_PROG_MKDIR_P + gl_HEADER_SYS_TIME_H + AC_PROG_MKDIR_P gl_SYS_TYPES_H AC_PROG_MKDIR_P gl_HEADER_TIME_H @@ -458,6 +469,7 @@ AC_DEFUN([gl_FILE_LIST], [ lib/fpucw.h lib/frexp.c lib/frexpl.c + lib/gettimeofday.c lib/inttypes.in.h lib/isnan.c lib/isnand-nolibm.h @@ -493,7 +505,6 @@ AC_DEFUN([gl_FILE_LIST], [ lib/stdbool.in.h lib/stddef.in.h lib/stdint.in.h - lib/stdio.c lib/stdio.in.h lib/stdlib.in.h lib/str-two-way.h @@ -505,6 +516,7 @@ AC_DEFUN([gl_FILE_LIST], [ lib/strstr.c lib/strtok_r.c lib/sys_stat.in.h + lib/sys_time.in.h lib/sys_types.in.h lib/time.in.h lib/unistd.c @@ -514,6 +526,7 @@ AC_DEFUN([gl_FILE_LIST], [ lib/wctype-h.c lib/wctype.in.h m4/00gnulib.m4 + m4/absolute-header.m4 m4/alloca.m4 m4/canonicalize.m4 m4/codeset.m4 @@ -534,6 +547,7 @@ AC_DEFUN([gl_FILE_LIST], [ m4/fpieee.m4 m4/frexp.m4 m4/frexpl.m4 + m4/gettimeofday.m4 m4/glibc21.m4 m4/gnulib-common.m4 m4/include_next.m4 @@ -575,7 +589,9 @@ AC_DEFUN([gl_FILE_LIST], [ m4/string_h.m4 m4/strstr.m4 m4/strtok_r.m4 + m4/sys_socket_h.m4 m4/sys_stat_h.m4 + m4/sys_time_h.m4 m4/sys_types_h.m4 m4/time_h.m4 m4/unistd_h.m4 diff --git a/gdb/gnulib/import/m4/gnulib-tool.m4 b/gdb/gnulib/import/m4/gnulib-tool.m4 index a09ffc1d1a0..fede1fc3bd1 100644 --- a/gdb/gnulib/import/m4/gnulib-tool.m4 +++ b/gdb/gnulib/import/m4/gnulib-tool.m4 @@ -1,5 +1,5 @@ # gnulib-tool.m4 serial 2 -dnl Copyright (C) 2004-2005, 2009-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2004-2005, 2009-2015 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. diff --git a/gdb/gnulib/import/m4/include_next.m4 b/gdb/gnulib/import/m4/include_next.m4 index a60a2614dc8..233d254e808 100644 --- a/gdb/gnulib/import/m4/include_next.m4 +++ b/gdb/gnulib/import/m4/include_next.m4 @@ -1,5 +1,5 @@ # include_next.m4 serial 23 -dnl Copyright (C) 2006-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2006-2015 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. @@ -192,56 +192,9 @@ dnl until we can assume autoconf 2.64 or newer. if test AS_VAR_GET(gl_header_exists) = yes; then AS_VAR_POPDEF([gl_header_exists]) ]) - AC_LANG_CONFTEST( - [AC_LANG_SOURCE( - [[#include <]]m4_dquote(m4_defn([gl_HEADER_NAME]))[[>]] - )]) - dnl AIX "xlc -E" and "cc -E" omit #line directives for header - dnl files that contain only a #include of other header files and - dnl no non-comment tokens of their own. This leads to a failure - dnl to detect the absolute name of <dirent.h>, <signal.h>, - dnl <poll.h> and others. The workaround is to force preservation - dnl of comments through option -C. This ensures all necessary - dnl #line directives are present. GCC supports option -C as well. - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac -changequote(,) - case "$host_os" in - mingw*) - dnl For the sake of native Windows compilers (excluding gcc), - dnl treat backslash as a directory separator, like /. - dnl Actually, these compilers use a double-backslash as - dnl directory separator, inside the - dnl # line "filename" - dnl directives. - gl_dirsep_regex='[/\\]' - ;; - *) - gl_dirsep_regex='\/' - ;; - esac - dnl A sed expression that turns a string into a basic regular - dnl expression, for use within "/.../". - gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g' -changequote([,]) - gl_header_literal_regex=`echo ']m4_defn([gl_HEADER_NAME])[' \ - | sed -e "$gl_make_literal_regex_sed"` - gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{ - s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/ -changequote(,)dnl - s|^/[^/]|//&| -changequote([,])dnl - p - q - }' - dnl eval is necessary to expand gl_absname_cpp. - dnl Ultrix and Pyramid sh refuse to redirect output of eval, - dnl so use subshell. - AS_VAR_SET(gl_next_header, - ['"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&AS_MESSAGE_LOG_FD | - sed -n "$gl_absolute_header_sed"`'"']) + gl_ABSOLUTE_HEADER_ONE(gl_HEADER_NAME) + AS_VAR_COPY([gl_header], [gl_cv_absolute_]AS_TR_SH(gl_HEADER_NAME)) + AS_VAR_SET(gl_next_header, ['"'$gl_header'"']) m4_if([$2], [check], [else AS_VAR_SET(gl_next_header, ['<'gl_HEADER_NAME'>']) diff --git a/gdb/gnulib/import/m4/inttypes-pri.m4 b/gdb/gnulib/import/m4/inttypes-pri.m4 index 977206fae89..0884e71e672 100644 --- a/gdb/gnulib/import/m4/inttypes-pri.m4 +++ b/gdb/gnulib/import/m4/inttypes-pri.m4 @@ -1,5 +1,5 @@ # inttypes-pri.m4 serial 7 (gettext-0.18.2) -dnl Copyright (C) 1997-2002, 2006, 2008-2012 Free Software Foundation, Inc. +dnl Copyright (C) 1997-2002, 2006, 2008-2015 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. diff --git a/gdb/gnulib/import/m4/inttypes.m4 b/gdb/gnulib/import/m4/inttypes.m4 index eec4f41d032..4209ffd1509 100644 --- a/gdb/gnulib/import/m4/inttypes.m4 +++ b/gdb/gnulib/import/m4/inttypes.m4 @@ -1,5 +1,5 @@ # inttypes.m4 serial 26 -dnl Copyright (C) 2006-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2006-2015 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. @@ -148,6 +148,7 @@ AC_DEFUN([gl_INTTYPES_H_DEFAULTS], HAVE_DECL_STRTOIMAX=1; AC_SUBST([HAVE_DECL_STRTOIMAX]) HAVE_DECL_STRTOUMAX=1; AC_SUBST([HAVE_DECL_STRTOUMAX]) REPLACE_STRTOIMAX=0; AC_SUBST([REPLACE_STRTOIMAX]) + REPLACE_STRTOUMAX=0; AC_SUBST([REPLACE_STRTOUMAX]) INT32_MAX_LT_INTMAX_MAX=1; AC_SUBST([INT32_MAX_LT_INTMAX_MAX]) INT64_MAX_EQ_LONG_MAX='defined _LP64'; AC_SUBST([INT64_MAX_EQ_LONG_MAX]) PRI_MACROS_BROKEN=0; AC_SUBST([PRI_MACROS_BROKEN]) diff --git a/gdb/gnulib/import/m4/isnand.m4 b/gdb/gnulib/import/m4/isnand.m4 index 54b64a452d8..4d5c615bc14 100644 --- a/gdb/gnulib/import/m4/isnand.m4 +++ b/gdb/gnulib/import/m4/isnand.m4 @@ -1,5 +1,5 @@ # isnand.m4 serial 11 -dnl Copyright (C) 2007-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2007-2015 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. diff --git a/gdb/gnulib/import/m4/isnanl.m4 b/gdb/gnulib/import/m4/isnanl.m4 index 81469ab8c86..b86ca9efec1 100644 --- a/gdb/gnulib/import/m4/isnanl.m4 +++ b/gdb/gnulib/import/m4/isnanl.m4 @@ -1,5 +1,5 @@ -# isnanl.m4 serial 17 -dnl Copyright (C) 2007-2012 Free Software Foundation, Inc. +# isnanl.m4 serial 19 +dnl Copyright (C) 2007-2015 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. @@ -108,11 +108,8 @@ AC_DEFUN([gl_HAVE_ISNANL_IN_LIBM], ]) ]) -dnl Test whether isnanl() recognizes all numbers which are neither finite nor -dnl infinite. This test fails e.g. on NetBSD/i386 and on glibc/ia64. -dnl Also, the GCC >= 4.0 built-in __builtin_isnanl does not pass the tests -dnl - for pseudo-denormals on i686 and x86_64, -dnl - for pseudo-zeroes, unnormalized numbers, and pseudo-denormals on ia64. +dnl Test whether isnanl() recognizes all canonical numbers which are neither +dnl finite nor infinite. AC_DEFUN([gl_FUNC_ISNANL_WORKS], [ AC_REQUIRE([AC_PROG_CC]) @@ -177,7 +174,7 @@ int main () # ifdef WORDS_BIGENDIAN # define LDBL80_WORDS(exponent,manthi,mantlo) \ { ((unsigned int) (exponent) << 16) | ((unsigned int) (manthi) >> 16), \ - ((unsigned int) (manthi) << 16) | (unsigned int) (mantlo) >> 16), \ + ((unsigned int) (manthi) << 16) | ((unsigned int) (mantlo) >> 16), \ (unsigned int) (mantlo) << 16 \ } # else @@ -197,41 +194,35 @@ int main () if (!isnanl (x.value)) result |= 2; } - /* The isnanl function should recognize Pseudo-NaNs, Pseudo-Infinities, - Pseudo-Zeroes, Unnormalized Numbers, and Pseudo-Denormals, as defined in - Intel IA-64 Architecture Software Developer's Manual, Volume 1: - Application Architecture. - Table 5-2 "Floating-Point Register Encodings" - Figure 5-6 "Memory to Floating-Point Register Data Translation" - */ + /* isnanl should return something even for noncanonical values. */ { /* Pseudo-NaN. */ static memory_long_double x = { LDBL80_WORDS (0xFFFF, 0x40000001, 0x00000000) }; - if (!isnanl (x.value)) + if (isnanl (x.value) && !isnanl (x.value)) result |= 4; } { /* Pseudo-Infinity. */ static memory_long_double x = { LDBL80_WORDS (0xFFFF, 0x00000000, 0x00000000) }; - if (!isnanl (x.value)) + if (isnanl (x.value) && !isnanl (x.value)) result |= 8; } { /* Pseudo-Zero. */ static memory_long_double x = { LDBL80_WORDS (0x4004, 0x00000000, 0x00000000) }; - if (!isnanl (x.value)) + if (isnanl (x.value) && !isnanl (x.value)) result |= 16; } { /* Unnormalized number. */ static memory_long_double x = { LDBL80_WORDS (0x4000, 0x63333333, 0x00000000) }; - if (!isnanl (x.value)) + if (isnanl (x.value) && !isnanl (x.value)) result |= 32; } { /* Pseudo-Denormal. */ static memory_long_double x = { LDBL80_WORDS (0x0000, 0x83333333, 0x00000000) }; - if (!isnanl (x.value)) + if (isnanl (x.value) && !isnanl (x.value)) result |= 64; } #endif @@ -240,16 +231,6 @@ int main () }]])], [gl_cv_func_isnanl_works=yes], [gl_cv_func_isnanl_works=no], - [case "$host_cpu" in - # Guess no on ia64, x86_64, i386. - ia64 | x86_64 | i*86) gl_cv_func_isnanl_works="guessing no";; - *) - case "$host_os" in - netbsd*) gl_cv_func_isnanl_works="guessing no";; - *) gl_cv_func_isnanl_works="guessing yes";; - esac - ;; - esac - ]) + [gl_cv_func_isnanl_works="guessing yes"]) ]) ]) diff --git a/gdb/gnulib/import/m4/largefile.m4 b/gdb/gnulib/import/m4/largefile.m4 index a88850afedc..b7a6c48b680 100644 --- a/gdb/gnulib/import/m4/largefile.m4 +++ b/gdb/gnulib/import/m4/largefile.m4 @@ -1,13 +1,14 @@ # Enable large files on systems where this is not the default. -# Copyright 1992-1996, 1998-2012 Free Software Foundation, Inc. +# Copyright 1992-1996, 1998-2015 Free Software Foundation, Inc. # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# The following implementation works around a problem in autoconf <= 2.68; -# AC_SYS_LARGEFILE does not configure for large inodes on Mac OS X 10.5. -m4_version_prereq([2.69], [] ,[ +# The following implementation works around a problem in autoconf <= 2.69; +# AC_SYS_LARGEFILE does not configure for large inodes on Mac OS X 10.5, +# or configures them incorrectly in some cases. +m4_version_prereq([2.70], [] ,[ # _AC_SYS_LARGEFILE_TEST_INCLUDES # ------------------------------- @@ -25,9 +26,9 @@ m4_define([_AC_SYS_LARGEFILE_TEST_INCLUDES], # _AC_SYS_LARGEFILE_MACRO_VALUE(C-MACRO, VALUE, -# CACHE-VAR, -# DESCRIPTION, -# PROLOGUE, [FUNCTION-BODY]) +# CACHE-VAR, +# DESCRIPTION, +# PROLOGUE, [FUNCTION-BODY]) # -------------------------------------------------------- m4_define([_AC_SYS_LARGEFILE_MACRO_VALUE], [AC_CACHE_CHECK([for $1 value needed for large files], [$3], @@ -93,15 +94,11 @@ if test "$enable_largefile" != no; then [_AC_SYS_LARGEFILE_TEST_INCLUDES]) fi - AH_VERBATIM([_DARWIN_USE_64_BIT_INODE], -[/* Enable large inode numbers on Mac OS X. */ -#ifndef _DARWIN_USE_64_BIT_INODE -# define _DARWIN_USE_64_BIT_INODE 1 -#endif]) + AC_DEFINE([_DARWIN_USE_64_BIT_INODE], [1], + [Enable large inode numbers on Mac OS X 10.5.]) fi ])# AC_SYS_LARGEFILE - -])# m4_version_prereq 2.69 +])# m4_version_prereq 2.70 # Enable large files on systems where this is implemented by Gnulib, not by the # system headers. diff --git a/gdb/gnulib/import/m4/localcharset.m4 b/gdb/gnulib/import/m4/localcharset.m4 index 8010379b18a..f03916c024e 100644 --- a/gdb/gnulib/import/m4/localcharset.m4 +++ b/gdb/gnulib/import/m4/localcharset.m4 @@ -1,5 +1,5 @@ # localcharset.m4 serial 7 -dnl Copyright (C) 2002, 2004, 2006, 2009-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2002, 2004, 2006, 2009-2015 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. diff --git a/gdb/gnulib/import/m4/locale-fr.m4 b/gdb/gnulib/import/m4/locale-fr.m4 index 71b68476c61..92ff55250ed 100644 --- a/gdb/gnulib/import/m4/locale-fr.m4 +++ b/gdb/gnulib/import/m4/locale-fr.m4 @@ -1,5 +1,5 @@ # locale-fr.m4 serial 17 -dnl Copyright (C) 2003, 2005-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2003, 2005-2015 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. diff --git a/gdb/gnulib/import/m4/locale-ja.m4 b/gdb/gnulib/import/m4/locale-ja.m4 index 5ba0e4381aa..a3abef87773 100644 --- a/gdb/gnulib/import/m4/locale-ja.m4 +++ b/gdb/gnulib/import/m4/locale-ja.m4 @@ -1,5 +1,5 @@ # locale-ja.m4 serial 12 -dnl Copyright (C) 2003, 2005-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2003, 2005-2015 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. diff --git a/gdb/gnulib/import/m4/locale-zh.m4 b/gdb/gnulib/import/m4/locale-zh.m4 index e5502b29e1d..c5c4ef65928 100644 --- a/gdb/gnulib/import/m4/locale-zh.m4 +++ b/gdb/gnulib/import/m4/locale-zh.m4 @@ -1,5 +1,5 @@ # locale-zh.m4 serial 12 -dnl Copyright (C) 2003, 2005-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2003, 2005-2015 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. diff --git a/gdb/gnulib/import/m4/longlong.m4 b/gdb/gnulib/import/m4/longlong.m4 index b9c65c756ee..d57bc700d4f 100644 --- a/gdb/gnulib/import/m4/longlong.m4 +++ b/gdb/gnulib/import/m4/longlong.m4 @@ -1,5 +1,5 @@ # longlong.m4 serial 17 -dnl Copyright (C) 1999-2007, 2009-2012 Free Software Foundation, Inc. +dnl Copyright (C) 1999-2007, 2009-2015 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. diff --git a/gdb/gnulib/import/m4/lstat.m4 b/gdb/gnulib/import/m4/lstat.m4 index 01b4eb953d5..adf752c0dfa 100644 --- a/gdb/gnulib/import/m4/lstat.m4 +++ b/gdb/gnulib/import/m4/lstat.m4 @@ -1,6 +1,6 @@ -# serial 26 +# serial 27 -# Copyright (C) 1997-2001, 2003-2012 Free Software Foundation, Inc. +# Copyright (C) 1997-2001, 2003-2015 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -37,30 +37,28 @@ AC_DEFUN([gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK], [gl_cv_func_lstat_dereferences_slashed_symlink], [rm -f conftest.sym conftest.file echo >conftest.file - if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then - AC_RUN_IFELSE( - [AC_LANG_PROGRAM( - [AC_INCLUDES_DEFAULT], - [[struct stat sbuf; - /* Linux will dereference the symlink and fail, as required by - POSIX. That is better in the sense that it means we will not - have to compile and use the lstat wrapper. */ - return lstat ("conftest.sym/", &sbuf) == 0; - ]])], - [gl_cv_func_lstat_dereferences_slashed_symlink=yes], - [gl_cv_func_lstat_dereferences_slashed_symlink=no], - [case "$host_os" in - # Guess yes on glibc systems. - *-gnu*) gl_cv_func_lstat_dereferences_slashed_symlink="guessing yes" ;; - # If we don't know, assume the worst. - *) gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" ;; - esac - ]) - else - # If the 'ln -s' command failed, then we probably don't even - # have an lstat function. - gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" - fi + AC_RUN_IFELSE( + [AC_LANG_PROGRAM( + [AC_INCLUDES_DEFAULT], + [[struct stat sbuf; + if (symlink ("conftest.file", "conftest.sym") != 0) + return 1; + /* Linux will dereference the symlink and fail, as required by + POSIX. That is better in the sense that it means we will not + have to compile and use the lstat wrapper. */ + return lstat ("conftest.sym/", &sbuf) == 0; + ]])], + [gl_cv_func_lstat_dereferences_slashed_symlink=yes], + [gl_cv_func_lstat_dereferences_slashed_symlink=no], + [case "$host_os" in + *-gnu*) + # Guess yes on glibc systems. + gl_cv_func_lstat_dereferences_slashed_symlink="guessing yes" ;; + *) + # If we don't know, assume the worst. + gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" ;; + esac + ]) rm -f conftest.sym conftest.file ]) case "$gl_cv_func_lstat_dereferences_slashed_symlink" in diff --git a/gdb/gnulib/import/m4/malloc.m4 b/gdb/gnulib/import/m4/malloc.m4 index 8fa48e93bc2..31368ab97fb 100644 --- a/gdb/gnulib/import/m4/malloc.m4 +++ b/gdb/gnulib/import/m4/malloc.m4 @@ -1,5 +1,5 @@ # malloc.m4 serial 14 -dnl Copyright (C) 2007, 2009-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2007, 2009-2015 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. diff --git a/gdb/gnulib/import/m4/malloca.m4 b/gdb/gnulib/import/m4/malloca.m4 index 7841979f3c9..72489517460 100644 --- a/gdb/gnulib/import/m4/malloca.m4 +++ b/gdb/gnulib/import/m4/malloca.m4 @@ -1,5 +1,5 @@ # malloca.m4 serial 1 -dnl Copyright (C) 2003-2004, 2006-2007, 2009-2012 Free Software Foundation, +dnl Copyright (C) 2003-2004, 2006-2007, 2009-2015 Free Software Foundation, dnl Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, diff --git a/gdb/gnulib/import/m4/math_h.m4 b/gdb/gnulib/import/m4/math_h.m4 index 338e80dd157..7d0f58346b7 100644 --- a/gdb/gnulib/import/m4/math_h.m4 +++ b/gdb/gnulib/import/m4/math_h.m4 @@ -1,5 +1,5 @@ # math_h.m4 serial 114 -dnl Copyright (C) 2007-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2007-2015 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. diff --git a/gdb/gnulib/import/m4/mbrtowc.m4 b/gdb/gnulib/import/m4/mbrtowc.m4 index 8f829c8ea59..c0d751dc84e 100644 --- a/gdb/gnulib/import/m4/mbrtowc.m4 +++ b/gdb/gnulib/import/m4/mbrtowc.m4 @@ -1,5 +1,5 @@ -# mbrtowc.m4 serial 25 -dnl Copyright (C) 2001-2002, 2004-2005, 2008-2012 Free Software Foundation, +# mbrtowc.m4 serial 26 +dnl Copyright (C) 2001-2002, 2004-2005, 2008-2015 Free Software Foundation, dnl Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, @@ -39,6 +39,7 @@ AC_DEFUN([gl_FUNC_MBRTOWC], gl_MBRTOWC_NULL_ARG2 gl_MBRTOWC_RETVAL gl_MBRTOWC_NUL_RETVAL + gl_MBRTOWC_EMPTY_INPUT case "$gl_cv_func_mbrtowc_null_arg1" in *yes) ;; *) AC_DEFINE([MBRTOWC_NULL_ARG1_BUG], [1], @@ -67,6 +68,14 @@ AC_DEFUN([gl_FUNC_MBRTOWC], REPLACE_MBRTOWC=1 ;; esac + case "$gl_cv_func_mbrtowc_empty_input" in + *yes) ;; + *) AC_DEFINE([MBRTOWC_EMPTY_INPUT_BUG], [1], + [Define if the mbrtowc function does not return (size_t) -2 + for empty input.]) + REPLACE_MBRTOWC=1 + ;; + esac fi fi ]) @@ -533,6 +542,41 @@ int main () ]) ]) +dnl Test whether mbrtowc returns the correct value on empty input. + +AC_DEFUN([gl_MBRTOWC_EMPTY_INPUT], +[ + AC_REQUIRE([AC_PROG_CC]) + AC_REQUIRE([AC_CANONICAL_HOST]) dnl for cross-compiles + AC_CACHE_CHECK([whether mbrtowc works on empty input], + [gl_cv_func_mbrtowc_empty_input], + [ + dnl Initial guess, used when cross-compiling or when no suitable locale + dnl is present. +changequote(,)dnl + case "$host_os" in + # Guess no on AIX and glibc systems. + aix* | *-gnu*) + gl_cv_func_mbrtowc_empty_input="guessing no" ;; + *) gl_cv_func_mbrtowc_empty_input="guessing yes" ;; + esac +changequote([,])dnl + AC_RUN_IFELSE( + [AC_LANG_SOURCE([[ + #include <wchar.h> + static wchar_t wc; + static mbstate_t mbs; + int + main (void) + { + return mbrtowc (&wc, "", 0, &mbs) == (size_t) -2; + }]])], + [gl_cv_func_mbrtowc_empty_input=no], + [gl_cv_func_mbrtowc_empty_input=yes], + [:]) + ]) +]) + # Prerequisites of lib/mbrtowc.c. AC_DEFUN([gl_PREREQ_MBRTOWC], [ : diff --git a/gdb/gnulib/import/m4/mbsinit.m4 b/gdb/gnulib/import/m4/mbsinit.m4 index da56c3d11b2..61c40329021 100644 --- a/gdb/gnulib/import/m4/mbsinit.m4 +++ b/gdb/gnulib/import/m4/mbsinit.m4 @@ -1,5 +1,5 @@ # mbsinit.m4 serial 8 -dnl Copyright (C) 2008, 2010-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2008, 2010-2015 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. diff --git a/gdb/gnulib/import/m4/mbsrtowcs.m4 b/gdb/gnulib/import/m4/mbsrtowcs.m4 index a95f6064a06..cea47e51be9 100644 --- a/gdb/gnulib/import/m4/mbsrtowcs.m4 +++ b/gdb/gnulib/import/m4/mbsrtowcs.m4 @@ -1,5 +1,5 @@ # mbsrtowcs.m4 serial 13 -dnl Copyright (C) 2008-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2008-2015 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. diff --git a/gdb/gnulib/import/m4/mbstate_t.m4 b/gdb/gnulib/import/m4/mbstate_t.m4 index 61a8190ce75..42ad6cd632e 100644 --- a/gdb/gnulib/import/m4/mbstate_t.m4 +++ b/gdb/gnulib/import/m4/mbstate_t.m4 @@ -1,5 +1,5 @@ # mbstate_t.m4 serial 13 -dnl Copyright (C) 2000-2002, 2008-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2000-2002, 2008-2015 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. diff --git a/gdb/gnulib/import/m4/memchr.m4 b/gdb/gnulib/import/m4/memchr.m4 index 004029450f0..cb958d86268 100644 --- a/gdb/gnulib/import/m4/memchr.m4 +++ b/gdb/gnulib/import/m4/memchr.m4 @@ -1,5 +1,5 @@ # memchr.m4 serial 12 -dnl Copyright (C) 2002-2004, 2009-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2002-2004, 2009-2015 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. diff --git a/gdb/gnulib/import/m4/memmem.m4 b/gdb/gnulib/import/m4/memmem.m4 index 88f9e20521f..80f2b1e3399 100644 --- a/gdb/gnulib/import/m4/memmem.m4 +++ b/gdb/gnulib/import/m4/memmem.m4 @@ -1,5 +1,5 @@ # memmem.m4 serial 24 -dnl Copyright (C) 2002-2004, 2007-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2002-2004, 2007-2015 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. diff --git a/gdb/gnulib/import/m4/mmap-anon.m4 b/gdb/gnulib/import/m4/mmap-anon.m4 index 748b17d97af..92a88d05fb0 100644 --- a/gdb/gnulib/import/m4/mmap-anon.m4 +++ b/gdb/gnulib/import/m4/mmap-anon.m4 @@ -1,5 +1,5 @@ # mmap-anon.m4 serial 10 -dnl Copyright (C) 2005, 2007, 2009-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2005, 2007, 2009-2015 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. diff --git a/gdb/gnulib/import/m4/multiarch.m4 b/gdb/gnulib/import/m4/multiarch.m4 index 0c288b8d2a9..fc575c1d437 100644 --- a/gdb/gnulib/import/m4/multiarch.m4 +++ b/gdb/gnulib/import/m4/multiarch.m4 @@ -1,5 +1,5 @@ # multiarch.m4 serial 7 -dnl Copyright (C) 2008-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2008-2015 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. diff --git a/gdb/gnulib/import/m4/nocrash.m4 b/gdb/gnulib/import/m4/nocrash.m4 index c2638df626c..56283180f04 100644 --- a/gdb/gnulib/import/m4/nocrash.m4 +++ b/gdb/gnulib/import/m4/nocrash.m4 @@ -1,5 +1,5 @@ # nocrash.m4 serial 4 -dnl Copyright (C) 2005, 2009-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2005, 2009-2015 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. diff --git a/gdb/gnulib/import/m4/off_t.m4 b/gdb/gnulib/import/m4/off_t.m4 index dfca2dfd233..0eb14678be1 100644 --- a/gdb/gnulib/import/m4/off_t.m4 +++ b/gdb/gnulib/import/m4/off_t.m4 @@ -1,5 +1,5 @@ # off_t.m4 serial 1 -dnl Copyright (C) 2012 Free Software Foundation, Inc. +dnl Copyright (C) 2012-2015 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. diff --git a/gdb/gnulib/import/m4/pathmax.m4 b/gdb/gnulib/import/m4/pathmax.m4 index 011786129e0..0e3db7a237b 100644 --- a/gdb/gnulib/import/m4/pathmax.m4 +++ b/gdb/gnulib/import/m4/pathmax.m4 @@ -1,5 +1,5 @@ # pathmax.m4 serial 10 -dnl Copyright (C) 2002-2003, 2005-2006, 2009-2012 Free Software Foundation, +dnl Copyright (C) 2002-2003, 2005-2006, 2009-2015 Free Software Foundation, dnl Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, diff --git a/gdb/gnulib/import/m4/readlink.m4 b/gdb/gnulib/import/m4/readlink.m4 index ccf5141d40b..88c9bfef717 100644 --- a/gdb/gnulib/import/m4/readlink.m4 +++ b/gdb/gnulib/import/m4/readlink.m4 @@ -1,5 +1,5 @@ # readlink.m4 serial 12 -dnl Copyright (C) 2003, 2007, 2009-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2003, 2007, 2009-2015 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. diff --git a/gdb/gnulib/import/m4/rename.m4 b/gdb/gnulib/import/m4/rename.m4 index 378b5ecfce9..b5e4334574d 100644 --- a/gdb/gnulib/import/m4/rename.m4 +++ b/gdb/gnulib/import/m4/rename.m4 @@ -1,6 +1,6 @@ # serial 26 -# Copyright (C) 2001, 2003, 2005-2006, 2009-2012 Free Software Foundation, Inc. +# Copyright (C) 2001, 2003, 2005-2006, 2009-2015 Free Software Foundation, Inc. # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. diff --git a/gdb/gnulib/import/m4/rmdir.m4 b/gdb/gnulib/import/m4/rmdir.m4 index 34ca87639bc..09ed159e046 100644 --- a/gdb/gnulib/import/m4/rmdir.m4 +++ b/gdb/gnulib/import/m4/rmdir.m4 @@ -1,5 +1,5 @@ # rmdir.m4 serial 13 -dnl Copyright (C) 2002, 2005, 2009-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2002, 2005, 2009-2015 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. diff --git a/gdb/gnulib/import/m4/ssize_t.m4 b/gdb/gnulib/import/m4/ssize_t.m4 index 209d64c8235..25bd4514343 100644 --- a/gdb/gnulib/import/m4/ssize_t.m4 +++ b/gdb/gnulib/import/m4/ssize_t.m4 @@ -1,5 +1,5 @@ # ssize_t.m4 serial 5 (gettext-0.18.2) -dnl Copyright (C) 2001-2003, 2006, 2010-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2001-2003, 2006, 2010-2015 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. diff --git a/gdb/gnulib/import/m4/stat.m4 b/gdb/gnulib/import/m4/stat.m4 index 0fd117e05eb..d1b37689632 100644 --- a/gdb/gnulib/import/m4/stat.m4 +++ b/gdb/gnulib/import/m4/stat.m4 @@ -1,6 +1,6 @@ # serial 11 -# Copyright (C) 2009-2012 Free Software Foundation, Inc. +# Copyright (C) 2009-2015 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, diff --git a/gdb/gnulib/import/m4/stdbool.m4 b/gdb/gnulib/import/m4/stdbool.m4 index eabfa64579c..7273b822465 100644 --- a/gdb/gnulib/import/m4/stdbool.m4 +++ b/gdb/gnulib/import/m4/stdbool.m4 @@ -1,6 +1,6 @@ # Check for stdbool.h that conforms to C99. -dnl Copyright (C) 2002-2006, 2009-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2002-2006, 2009-2015 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. diff --git a/gdb/gnulib/import/m4/stddef_h.m4 b/gdb/gnulib/import/m4/stddef_h.m4 index cc116096093..231050274ad 100644 --- a/gdb/gnulib/import/m4/stddef_h.m4 +++ b/gdb/gnulib/import/m4/stddef_h.m4 @@ -1,6 +1,6 @@ -dnl A placeholder for POSIX 2008 <stddef.h>, for platforms that have issues. -# stddef_h.m4 serial 4 -dnl Copyright (C) 2009-2012 Free Software Foundation, Inc. +dnl A placeholder for <stddef.h>, for platforms that have issues. +# stddef_h.m4 serial 5 +dnl Copyright (C) 2009-2015 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. @@ -10,6 +10,9 @@ AC_DEFUN([gl_STDDEF_H], AC_REQUIRE([gl_STDDEF_H_DEFAULTS]) AC_REQUIRE([gt_TYPE_WCHAR_T]) STDDEF_H= + AC_CHECK_TYPE([max_align_t], [], [HAVE_MAX_ALIGN_T=0; STDDEF_H=stddef.h], + [[#include <stddef.h> + ]]) if test $gt_cv_c_wchar_t = no; then HAVE_WCHAR_T=0 STDDEF_H=stddef.h @@ -43,5 +46,6 @@ AC_DEFUN([gl_STDDEF_H_DEFAULTS], [ dnl Assume proper GNU behavior unless another module says otherwise. REPLACE_NULL=0; AC_SUBST([REPLACE_NULL]) + HAVE_MAX_ALIGN_T=1; AC_SUBST([HAVE_MAX_ALIGN_T]) HAVE_WCHAR_T=1; AC_SUBST([HAVE_WCHAR_T]) ]) diff --git a/gdb/gnulib/import/m4/stdint.m4 b/gdb/gnulib/import/m4/stdint.m4 index 28d342ea233..4011a4942a1 100644 --- a/gdb/gnulib/import/m4/stdint.m4 +++ b/gdb/gnulib/import/m4/stdint.m4 @@ -1,5 +1,5 @@ # stdint.m4 serial 43 -dnl Copyright (C) 2001-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2001-2015 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. diff --git a/gdb/gnulib/import/m4/stdio_h.m4 b/gdb/gnulib/import/m4/stdio_h.m4 index 3bd65803667..f60cc2156e0 100644 --- a/gdb/gnulib/import/m4/stdio_h.m4 +++ b/gdb/gnulib/import/m4/stdio_h.m4 @@ -1,14 +1,41 @@ -# stdio_h.m4 serial 43 -dnl Copyright (C) 2007-2012 Free Software Foundation, Inc. +# stdio_h.m4 serial 46 +dnl Copyright (C) 2007-2015 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. AC_DEFUN([gl_STDIO_H], [ + dnl For __USE_MINGW_ANSI_STDIO + AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS]) + AC_REQUIRE([gl_STDIO_H_DEFAULTS]) gl_NEXT_HEADERS([stdio.h]) + dnl Determine whether __USE_MINGW_ANSI_STDIO makes printf and + dnl inttypes.h behave like gnu instead of system; we must give our + dnl printf wrapper the right attribute to match. + AC_CACHE_CHECK([which flavor of printf attribute matches inttypes macros], + [gl_cv_func_printf_attribute_flavor], + [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ + #define __STDC_FORMAT_MACROS 1 + #include <stdio.h> + #include <inttypes.h> + /* For non-mingw systems, compilation will trivially succeed. + For mingw, compilation will succeed for older mingw (system + printf, "I64d") and fail for newer mingw (gnu printf, "lld"). */ + #if ((defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__) && \ + (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4)) + extern char PRIdMAX_probe[sizeof PRIdMAX == sizeof "I64d" ? 1 : -1]; + #endif + ]])], [gl_cv_func_printf_attribute_flavor=system], + [gl_cv_func_printf_attribute_flavor=gnu])]) + if test "$gl_cv_func_printf_attribute_flavor" = gnu; then + AC_DEFINE([GNULIB_PRINTF_ATTRIBUTE_FLAVOR_GNU], [1], + [Define to 1 if printf and friends should be labeled with + attribute "__gnu_printf__" instead of "__printf__"]) + fi + dnl No need to create extra modules for these functions. Everyone who uses dnl <stdio.h> likely needs them. GNULIB_FSCANF=1 diff --git a/gdb/gnulib/import/m4/stdlib_h.m4 b/gdb/gnulib/import/m4/stdlib_h.m4 index 9c69f2e4d15..0b4c623ec71 100644 --- a/gdb/gnulib/import/m4/stdlib_h.m4 +++ b/gdb/gnulib/import/m4/stdlib_h.m4 @@ -1,5 +1,5 @@ -# stdlib_h.m4 serial 41 -dnl Copyright (C) 2007-2012 Free Software Foundation, Inc. +# stdlib_h.m4 serial 42 +dnl Copyright (C) 2007-2015 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. @@ -22,7 +22,7 @@ AC_DEFUN([gl_STDLIB_H], ]], [_Exit atoll canonicalize_file_name getloadavg getsubopt grantpt initstate initstate_r mkdtemp mkostemp mkostemps mkstemp mkstemps posix_openpt ptsname ptsname_r random random_r realpath rpmatch - setenv setstate setstate_r srandom srandom_r + secure_getenv setenv setstate setstate_r srandom srandom_r strtod strtoll strtoull unlockpt unsetenv]) ]) @@ -55,11 +55,13 @@ AC_DEFUN([gl_STDLIB_H_DEFAULTS], GNULIB_PTSNAME=0; AC_SUBST([GNULIB_PTSNAME]) GNULIB_PTSNAME_R=0; AC_SUBST([GNULIB_PTSNAME_R]) GNULIB_PUTENV=0; AC_SUBST([GNULIB_PUTENV]) + GNULIB_QSORT_R=0; AC_SUBST([GNULIB_QSORT_R]) GNULIB_RANDOM=0; AC_SUBST([GNULIB_RANDOM]) GNULIB_RANDOM_R=0; AC_SUBST([GNULIB_RANDOM_R]) GNULIB_REALLOC_POSIX=0; AC_SUBST([GNULIB_REALLOC_POSIX]) GNULIB_REALPATH=0; AC_SUBST([GNULIB_REALPATH]) GNULIB_RPMATCH=0; AC_SUBST([GNULIB_RPMATCH]) + GNULIB_SECURE_GETENV=0; AC_SUBST([GNULIB_SECURE_GETENV]) GNULIB_SETENV=0; AC_SUBST([GNULIB_SETENV]) GNULIB_STRTOD=0; AC_SUBST([GNULIB_STRTOD]) GNULIB_STRTOLL=0; AC_SUBST([GNULIB_STRTOLL]) @@ -88,6 +90,7 @@ AC_DEFUN([gl_STDLIB_H_DEFAULTS], HAVE_RANDOM_R=1; AC_SUBST([HAVE_RANDOM_R]) HAVE_REALPATH=1; AC_SUBST([HAVE_REALPATH]) HAVE_RPMATCH=1; AC_SUBST([HAVE_RPMATCH]) + HAVE_SECURE_GETENV=1; AC_SUBST([HAVE_SECURE_GETENV]) HAVE_SETENV=1; AC_SUBST([HAVE_SETENV]) HAVE_DECL_SETENV=1; AC_SUBST([HAVE_DECL_SETENV]) HAVE_STRTOD=1; AC_SUBST([HAVE_STRTOD]) @@ -105,6 +108,7 @@ AC_DEFUN([gl_STDLIB_H_DEFAULTS], REPLACE_PTSNAME=0; AC_SUBST([REPLACE_PTSNAME]) REPLACE_PTSNAME_R=0; AC_SUBST([REPLACE_PTSNAME_R]) REPLACE_PUTENV=0; AC_SUBST([REPLACE_PUTENV]) + REPLACE_QSORT_R=0; AC_SUBST([REPLACE_QSORT_R]) REPLACE_RANDOM_R=0; AC_SUBST([REPLACE_RANDOM_R]) REPLACE_REALLOC=0; AC_SUBST([REPLACE_REALLOC]) REPLACE_REALPATH=0; AC_SUBST([REPLACE_REALPATH]) diff --git a/gdb/gnulib/import/m4/string_h.m4 b/gdb/gnulib/import/m4/string_h.m4 index 5677e092d44..55d09ef4078 100644 --- a/gdb/gnulib/import/m4/string_h.m4 +++ b/gdb/gnulib/import/m4/string_h.m4 @@ -1,6 +1,6 @@ # Configure a GNU-like replacement for <string.h>. -# Copyright (C) 2007-2012 Free Software Foundation, Inc. +# Copyright (C) 2007-2015 Free Software Foundation, Inc. # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. diff --git a/gdb/gnulib/import/m4/strstr.m4 b/gdb/gnulib/import/m4/strstr.m4 index b8f94bf7578..040c0b9dfd8 100644 --- a/gdb/gnulib/import/m4/strstr.m4 +++ b/gdb/gnulib/import/m4/strstr.m4 @@ -1,5 +1,5 @@ # strstr.m4 serial 16 -dnl Copyright (C) 2008-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2008-2015 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. diff --git a/gdb/gnulib/import/m4/strtok_r.m4 b/gdb/gnulib/import/m4/strtok_r.m4 index 60e33a695f5..9ed6a25c91b 100644 --- a/gdb/gnulib/import/m4/strtok_r.m4 +++ b/gdb/gnulib/import/m4/strtok_r.m4 @@ -1,5 +1,5 @@ # strtok_r.m4 serial 13 -dnl Copyright (C) 2002-2004, 2006-2007, 2009-2012 Free Software Foundation, +dnl Copyright (C) 2002-2004, 2006-2007, 2009-2015 Free Software Foundation, dnl Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, diff --git a/gdb/gnulib/import/m4/sys_socket_h.m4 b/gdb/gnulib/import/m4/sys_socket_h.m4 new file mode 100644 index 00000000000..eaeabe7d966 --- /dev/null +++ b/gdb/gnulib/import/m4/sys_socket_h.m4 @@ -0,0 +1,176 @@ +# sys_socket_h.m4 serial 23 +dnl Copyright (C) 2005-2015 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. + +dnl From Simon Josefsson. + +AC_DEFUN([gl_HEADER_SYS_SOCKET], +[ + AC_REQUIRE([gl_SYS_SOCKET_H_DEFAULTS]) + AC_REQUIRE([AC_CANONICAL_HOST]) + + dnl On OSF/1, the functions recv(), send(), recvfrom(), sendto() have + dnl old-style declarations (with return type 'int' instead of 'ssize_t') + dnl unless _POSIX_PII_SOCKET is defined. + case "$host_os" in + osf*) + AC_DEFINE([_POSIX_PII_SOCKET], [1], + [Define to 1 in order to get the POSIX compatible declarations + of socket functions.]) + ;; + esac + + AC_CACHE_CHECK([whether <sys/socket.h> is self-contained], + [gl_cv_header_sys_socket_h_selfcontained], + [ + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <sys/socket.h>]], [[]])], + [gl_cv_header_sys_socket_h_selfcontained=yes], + [gl_cv_header_sys_socket_h_selfcontained=no]) + ]) + if test $gl_cv_header_sys_socket_h_selfcontained = yes; then + dnl If the shutdown function exists, <sys/socket.h> should define + dnl SHUT_RD, SHUT_WR, SHUT_RDWR. + AC_CHECK_FUNCS([shutdown]) + if test $ac_cv_func_shutdown = yes; then + AC_CACHE_CHECK([whether <sys/socket.h> defines the SHUT_* macros], + [gl_cv_header_sys_socket_h_shut], + [ + AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM([[#include <sys/socket.h>]], + [[int a[] = { SHUT_RD, SHUT_WR, SHUT_RDWR };]])], + [gl_cv_header_sys_socket_h_shut=yes], + [gl_cv_header_sys_socket_h_shut=no]) + ]) + if test $gl_cv_header_sys_socket_h_shut = no; then + SYS_SOCKET_H='sys/socket.h' + fi + fi + fi + # We need to check for ws2tcpip.h now. + gl_PREREQ_SYS_H_SOCKET + AC_CHECK_TYPES([struct sockaddr_storage, sa_family_t],,,[ + /* sys/types.h is not needed according to POSIX, but the + sys/socket.h in i386-unknown-freebsd4.10 and + powerpc-apple-darwin5.5 required it. */ +#include <sys/types.h> +#ifdef HAVE_SYS_SOCKET_H +#include <sys/socket.h> +#endif +#ifdef HAVE_WS2TCPIP_H +#include <ws2tcpip.h> +#endif +]) + if test $ac_cv_type_struct_sockaddr_storage = no; then + HAVE_STRUCT_SOCKADDR_STORAGE=0 + fi + if test $ac_cv_type_sa_family_t = no; then + HAVE_SA_FAMILY_T=0 + fi + if test $ac_cv_type_struct_sockaddr_storage != no; then + AC_CHECK_MEMBERS([struct sockaddr_storage.ss_family], + [], + [HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY=0], + [#include <sys/types.h> + #ifdef HAVE_SYS_SOCKET_H + #include <sys/socket.h> + #endif + #ifdef HAVE_WS2TCPIP_H + #include <ws2tcpip.h> + #endif + ]) + fi + if test $HAVE_STRUCT_SOCKADDR_STORAGE = 0 || test $HAVE_SA_FAMILY_T = 0 \ + || test $HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY = 0; then + SYS_SOCKET_H='sys/socket.h' + fi + gl_PREREQ_SYS_H_WINSOCK2 + + dnl Check for declarations of anything we want to poison if the + dnl corresponding gnulib module is not in use. + gl_WARN_ON_USE_PREPARE([[ +/* Some systems require prerequisite headers. */ +#include <sys/types.h> +#include <sys/socket.h> + ]], [socket connect accept bind getpeername getsockname getsockopt + listen recv send recvfrom sendto setsockopt shutdown accept4]) +]) + +AC_DEFUN([gl_PREREQ_SYS_H_SOCKET], +[ + dnl Check prerequisites of the <sys/socket.h> replacement. + AC_REQUIRE([gl_CHECK_SOCKET_HEADERS]) + gl_CHECK_NEXT_HEADERS([sys/socket.h]) + if test $ac_cv_header_sys_socket_h = yes; then + HAVE_SYS_SOCKET_H=1 + HAVE_WS2TCPIP_H=0 + else + HAVE_SYS_SOCKET_H=0 + if test $ac_cv_header_ws2tcpip_h = yes; then + HAVE_WS2TCPIP_H=1 + else + HAVE_WS2TCPIP_H=0 + fi + fi + AC_SUBST([HAVE_SYS_SOCKET_H]) + AC_SUBST([HAVE_WS2TCPIP_H]) +]) + +# Common prerequisites of the <sys/socket.h> replacement and of the +# <sys/select.h> replacement. +# Sets and substitutes HAVE_WINSOCK2_H. +AC_DEFUN([gl_PREREQ_SYS_H_WINSOCK2], +[ + m4_ifdef([gl_UNISTD_H_DEFAULTS], [AC_REQUIRE([gl_UNISTD_H_DEFAULTS])]) + m4_ifdef([gl_SYS_IOCTL_H_DEFAULTS], [AC_REQUIRE([gl_SYS_IOCTL_H_DEFAULTS])]) + AC_CHECK_HEADERS_ONCE([sys/socket.h]) + if test $ac_cv_header_sys_socket_h != yes; then + dnl We cannot use AC_CHECK_HEADERS_ONCE here, because that would make + dnl the check for those headers unconditional; yet cygwin reports + dnl that the headers are present but cannot be compiled (since on + dnl cygwin, all socket information should come from sys/socket.h). + AC_CHECK_HEADERS([winsock2.h]) + fi + if test "$ac_cv_header_winsock2_h" = yes; then + HAVE_WINSOCK2_H=1 + UNISTD_H_HAVE_WINSOCK2_H=1 + SYS_IOCTL_H_HAVE_WINSOCK2_H=1 + else + HAVE_WINSOCK2_H=0 + fi + AC_SUBST([HAVE_WINSOCK2_H]) +]) + +AC_DEFUN([gl_SYS_SOCKET_MODULE_INDICATOR], +[ + dnl Use AC_REQUIRE here, so that the default settings are expanded once only. + AC_REQUIRE([gl_SYS_SOCKET_H_DEFAULTS]) + gl_MODULE_INDICATOR_SET_VARIABLE([$1]) + dnl Define it also as a C macro, for the benefit of the unit tests. + gl_MODULE_INDICATOR_FOR_TESTS([$1]) +]) + +AC_DEFUN([gl_SYS_SOCKET_H_DEFAULTS], +[ + GNULIB_SOCKET=0; AC_SUBST([GNULIB_SOCKET]) + GNULIB_CONNECT=0; AC_SUBST([GNULIB_CONNECT]) + GNULIB_ACCEPT=0; AC_SUBST([GNULIB_ACCEPT]) + GNULIB_BIND=0; AC_SUBST([GNULIB_BIND]) + GNULIB_GETPEERNAME=0; AC_SUBST([GNULIB_GETPEERNAME]) + GNULIB_GETSOCKNAME=0; AC_SUBST([GNULIB_GETSOCKNAME]) + GNULIB_GETSOCKOPT=0; AC_SUBST([GNULIB_GETSOCKOPT]) + GNULIB_LISTEN=0; AC_SUBST([GNULIB_LISTEN]) + GNULIB_RECV=0; AC_SUBST([GNULIB_RECV]) + GNULIB_SEND=0; AC_SUBST([GNULIB_SEND]) + GNULIB_RECVFROM=0; AC_SUBST([GNULIB_RECVFROM]) + GNULIB_SENDTO=0; AC_SUBST([GNULIB_SENDTO]) + GNULIB_SETSOCKOPT=0; AC_SUBST([GNULIB_SETSOCKOPT]) + GNULIB_SHUTDOWN=0; AC_SUBST([GNULIB_SHUTDOWN]) + GNULIB_ACCEPT4=0; AC_SUBST([GNULIB_ACCEPT4]) + HAVE_STRUCT_SOCKADDR_STORAGE=1; AC_SUBST([HAVE_STRUCT_SOCKADDR_STORAGE]) + HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY=1; + AC_SUBST([HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY]) + HAVE_SA_FAMILY_T=1; AC_SUBST([HAVE_SA_FAMILY_T]) + HAVE_ACCEPT4=1; AC_SUBST([HAVE_ACCEPT4]) +]) diff --git a/gdb/gnulib/import/m4/sys_stat_h.m4 b/gdb/gnulib/import/m4/sys_stat_h.m4 index 8af3353ea51..6c909e816a7 100644 --- a/gdb/gnulib/import/m4/sys_stat_h.m4 +++ b/gdb/gnulib/import/m4/sys_stat_h.m4 @@ -1,5 +1,5 @@ # sys_stat_h.m4 serial 28 -*- Autoconf -*- -dnl Copyright (C) 2006-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2006-2015 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. diff --git a/gdb/gnulib/import/m4/sys_time_h.m4 b/gdb/gnulib/import/m4/sys_time_h.m4 new file mode 100644 index 00000000000..28c8b1acbba --- /dev/null +++ b/gdb/gnulib/import/m4/sys_time_h.m4 @@ -0,0 +1,111 @@ +# Configure a replacement for <sys/time.h>. +# serial 8 + +# Copyright (C) 2007, 2009-2015 Free Software Foundation, Inc. +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# Written by Paul Eggert and Martin Lambers. + +AC_DEFUN([gl_HEADER_SYS_TIME_H], +[ + dnl Use AC_REQUIRE here, so that the REPLACE_GETTIMEOFDAY=0 statement + dnl below is expanded once only, before all REPLACE_GETTIMEOFDAY=1 + dnl statements that occur in other macros. + AC_REQUIRE([gl_HEADER_SYS_TIME_H_BODY]) +]) + +AC_DEFUN([gl_HEADER_SYS_TIME_H_BODY], +[ + AC_REQUIRE([AC_C_RESTRICT]) + AC_REQUIRE([gl_HEADER_SYS_TIME_H_DEFAULTS]) + AC_CHECK_HEADERS_ONCE([sys/time.h]) + gl_CHECK_NEXT_HEADERS([sys/time.h]) + + if test $ac_cv_header_sys_time_h != yes; then + HAVE_SYS_TIME_H=0 + fi + + dnl On native Windows with MSVC, 'struct timeval' is defined in <winsock2.h> + dnl only. So include that header in the list. + gl_PREREQ_SYS_H_WINSOCK2 + AC_CACHE_CHECK([for struct timeval], [gl_cv_sys_struct_timeval], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM( + [[#if HAVE_SYS_TIME_H + #include <sys/time.h> + #endif + #include <time.h> + #if HAVE_WINSOCK2_H + # include <winsock2.h> + #endif + ]], + [[static struct timeval x; x.tv_sec = x.tv_usec;]])], + [gl_cv_sys_struct_timeval=yes], + [gl_cv_sys_struct_timeval=no]) + ]) + if test $gl_cv_sys_struct_timeval != yes; then + HAVE_STRUCT_TIMEVAL=0 + else + dnl On native Windows with a 64-bit 'time_t', 'struct timeval' is defined + dnl (in <sys/time.h> and <winsock2.h> for mingw64, in <winsock2.h> only + dnl for MSVC) with a tv_sec field of type 'long' (32-bit!), which is + dnl smaller than the 'time_t' type mandated by POSIX. + dnl On OpenBSD 5.1 amd64, tv_sec is 64 bits and time_t 32 bits, but + dnl that is good enough. + AC_CACHE_CHECK([for wide-enough struct timeval.tv_sec member], + [gl_cv_sys_struct_timeval_tv_sec], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM( + [[#if HAVE_SYS_TIME_H + #include <sys/time.h> + #endif + #include <time.h> + #if HAVE_WINSOCK2_H + # include <winsock2.h> + #endif + ]], + [[static struct timeval x; + typedef int verify_tv_sec_type[ + sizeof (time_t) <= sizeof x.tv_sec ? 1 : -1 + ]; + ]])], + [gl_cv_sys_struct_timeval_tv_sec=yes], + [gl_cv_sys_struct_timeval_tv_sec=no]) + ]) + if test $gl_cv_sys_struct_timeval_tv_sec != yes; then + REPLACE_STRUCT_TIMEVAL=1 + fi + fi + + dnl Check for declarations of anything we want to poison if the + dnl corresponding gnulib module is not in use. + gl_WARN_ON_USE_PREPARE([[ +#if HAVE_SYS_TIME_H +# include <sys/time.h> +#endif +#include <time.h> + ]], [gettimeofday]) +]) + +AC_DEFUN([gl_SYS_TIME_MODULE_INDICATOR], +[ + dnl Use AC_REQUIRE here, so that the default settings are expanded once only. + AC_REQUIRE([gl_HEADER_SYS_TIME_H_DEFAULTS]) + gl_MODULE_INDICATOR_SET_VARIABLE([$1]) + dnl Define it also as a C macro, for the benefit of the unit tests. + gl_MODULE_INDICATOR_FOR_TESTS([$1]) +]) + +AC_DEFUN([gl_HEADER_SYS_TIME_H_DEFAULTS], +[ + GNULIB_GETTIMEOFDAY=0; AC_SUBST([GNULIB_GETTIMEOFDAY]) + dnl Assume POSIX behavior unless another module says otherwise. + HAVE_GETTIMEOFDAY=1; AC_SUBST([HAVE_GETTIMEOFDAY]) + HAVE_STRUCT_TIMEVAL=1; AC_SUBST([HAVE_STRUCT_TIMEVAL]) + HAVE_SYS_TIME_H=1; AC_SUBST([HAVE_SYS_TIME_H]) + HAVE_TIMEZONE_T=0; AC_SUBST([HAVE_TIMEZONE_T]) + REPLACE_GETTIMEOFDAY=0; AC_SUBST([REPLACE_GETTIMEOFDAY]) + REPLACE_STRUCT_TIMEVAL=0; AC_SUBST([REPLACE_STRUCT_TIMEVAL]) +]) diff --git a/gdb/gnulib/import/m4/sys_types_h.m4 b/gdb/gnulib/import/m4/sys_types_h.m4 index f11eef2fe8a..2232aece63e 100644 --- a/gdb/gnulib/import/m4/sys_types_h.m4 +++ b/gdb/gnulib/import/m4/sys_types_h.m4 @@ -1,10 +1,10 @@ -# sys_types_h.m4 serial 4 -dnl Copyright (C) 2011-2012 Free Software Foundation, Inc. +# sys_types_h.m4 serial 5 +dnl Copyright (C) 2011-2015 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. -AC_DEFUN([gl_SYS_TYPES_H], +AC_DEFUN_ONCE([gl_SYS_TYPES_H], [ AC_REQUIRE([gl_SYS_TYPES_H_DEFAULTS]) gl_NEXT_HEADERS([sys/types.h]) diff --git a/gdb/gnulib/import/m4/time_h.m4 b/gdb/gnulib/import/m4/time_h.m4 index 6415bfbcb74..754b469a0d9 100644 --- a/gdb/gnulib/import/m4/time_h.m4 +++ b/gdb/gnulib/import/m4/time_h.m4 @@ -1,8 +1,8 @@ # Configure a more-standard replacement for <time.h>. -# Copyright (C) 2000-2001, 2003-2007, 2009-2012 Free Software Foundation, Inc. +# Copyright (C) 2000-2001, 2003-2007, 2009-2015 Free Software Foundation, Inc. -# serial 7 +# serial 9 # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -26,7 +26,7 @@ AC_DEFUN([gl_HEADER_TIME_H_BODY], ]) dnl Check whether 'struct timespec' is declared -dnl in time.h, sys/time.h, or pthread.h. +dnl in time.h, sys/time.h, pthread.h, or unistd.h. AC_DEFUN([gl_CHECK_TYPE_STRUCT_TIMESPEC], [ @@ -44,6 +44,7 @@ AC_DEFUN([gl_CHECK_TYPE_STRUCT_TIMESPEC], TIME_H_DEFINES_STRUCT_TIMESPEC=0 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0 + UNISTD_H_DEFINES_STRUCT_TIMESPEC=0 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then TIME_H_DEFINES_STRUCT_TIMESPEC=1 else @@ -70,12 +71,26 @@ AC_DEFUN([gl_CHECK_TYPE_STRUCT_TIMESPEC], [gl_cv_sys_struct_timespec_in_pthread_h=no])]) if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1 + else + AC_CACHE_CHECK([for struct timespec in <unistd.h>], + [gl_cv_sys_struct_timespec_in_unistd_h], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM( + [[#include <unistd.h> + ]], + [[static struct timespec x; x.tv_sec = x.tv_nsec;]])], + [gl_cv_sys_struct_timespec_in_unistd_h=yes], + [gl_cv_sys_struct_timespec_in_unistd_h=no])]) + if test $gl_cv_sys_struct_timespec_in_unistd_h = yes; then + UNISTD_H_DEFINES_STRUCT_TIMESPEC=1 + fi fi fi fi AC_SUBST([TIME_H_DEFINES_STRUCT_TIMESPEC]) AC_SUBST([SYS_TIME_H_DEFINES_STRUCT_TIMESPEC]) AC_SUBST([PTHREAD_H_DEFINES_STRUCT_TIMESPEC]) + AC_SUBST([UNISTD_H_DEFINES_STRUCT_TIMESPEC]) ]) AC_DEFUN([gl_TIME_MODULE_INDICATOR], @@ -94,6 +109,7 @@ AC_DEFUN([gl_HEADER_TIME_H_DEFAULTS], GNULIB_STRPTIME=0; AC_SUBST([GNULIB_STRPTIME]) GNULIB_TIMEGM=0; AC_SUBST([GNULIB_TIMEGM]) GNULIB_TIME_R=0; AC_SUBST([GNULIB_TIME_R]) + GNULIB_TIME_RZ=0; AC_SUBST([GNULIB_TIME_RZ]) dnl Assume proper GNU behavior unless another module says otherwise. HAVE_DECL_LOCALTIME_R=1; AC_SUBST([HAVE_DECL_LOCALTIME_R]) HAVE_NANOSLEEP=1; AC_SUBST([HAVE_NANOSLEEP]) @@ -106,4 +122,13 @@ AC_DEFUN([gl_HEADER_TIME_H_DEFAULTS], REPLACE_MKTIME=GNULIB_PORTCHECK; AC_SUBST([REPLACE_MKTIME]) REPLACE_NANOSLEEP=GNULIB_PORTCHECK; AC_SUBST([REPLACE_NANOSLEEP]) REPLACE_TIMEGM=GNULIB_PORTCHECK; AC_SUBST([REPLACE_TIMEGM]) + + dnl Hack so that the time module doesn't depend on the sys_time module. + dnl First, default GNULIB_GETTIMEOFDAY to 0 if sys_time is absent. + : ${GNULIB_GETTIMEOFDAY=0}; AC_SUBST([GNULIB_GETTIMEOFDAY]) + dnl Second, it's OK to not use GNULIB_PORTCHECK for REPLACE_GMTIME + dnl and REPLACE_LOCALTIME, as portability to Solaris 2.6 and earlier + dnl is no longer a big deal. + REPLACE_GMTIME=0; AC_SUBST([REPLACE_GMTIME]) + REPLACE_LOCALTIME=0; AC_SUBST([REPLACE_LOCALTIME]) ]) diff --git a/gdb/gnulib/import/m4/unistd_h.m4 b/gdb/gnulib/import/m4/unistd_h.m4 index f68fbff8cef..b3c581f7b25 100644 --- a/gdb/gnulib/import/m4/unistd_h.m4 +++ b/gdb/gnulib/import/m4/unistd_h.m4 @@ -1,5 +1,5 @@ -# unistd_h.m4 serial 66 -dnl Copyright (C) 2006-2012 Free Software Foundation, Inc. +# unistd_h.m4 serial 68 +dnl Copyright (C) 2006-2015 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. @@ -160,6 +160,7 @@ AC_DEFUN([gl_UNISTD_H_DEFAULTS], REPLACE_FTRUNCATE=0; AC_SUBST([REPLACE_FTRUNCATE]) REPLACE_GETCWD=0; AC_SUBST([REPLACE_GETCWD]) REPLACE_GETDOMAINNAME=0; AC_SUBST([REPLACE_GETDOMAINNAME]) + REPLACE_GETDTABLESIZE=0; AC_SUBST([REPLACE_GETDTABLESIZE]) REPLACE_GETLOGIN_R=0; AC_SUBST([REPLACE_GETLOGIN_R]) REPLACE_GETGROUPS=0; AC_SUBST([REPLACE_GETGROUPS]) REPLACE_GETPAGESIZE=0; AC_SUBST([REPLACE_GETPAGESIZE]) @@ -172,9 +173,11 @@ AC_DEFUN([gl_UNISTD_H_DEFAULTS], REPLACE_PWRITE=0; AC_SUBST([REPLACE_PWRITE]) REPLACE_READ=0; AC_SUBST([REPLACE_READ]) REPLACE_READLINK=0; AC_SUBST([REPLACE_READLINK]) + REPLACE_READLINKAT=0; AC_SUBST([REPLACE_READLINKAT]) REPLACE_RMDIR=0; AC_SUBST([REPLACE_RMDIR]) REPLACE_SLEEP=0; AC_SUBST([REPLACE_SLEEP]) REPLACE_SYMLINK=0; AC_SUBST([REPLACE_SYMLINK]) + REPLACE_SYMLINKAT=0; AC_SUBST([REPLACE_SYMLINKAT]) REPLACE_TTYNAME_R=0; AC_SUBST([REPLACE_TTYNAME_R]) REPLACE_UNLINK=0; AC_SUBST([REPLACE_UNLINK]) REPLACE_UNLINKAT=0; AC_SUBST([REPLACE_UNLINKAT]) diff --git a/gdb/gnulib/import/m4/warn-on-use.m4 b/gdb/gnulib/import/m4/warn-on-use.m4 index a77802eb916..1e98dc9b775 100644 --- a/gdb/gnulib/import/m4/warn-on-use.m4 +++ b/gdb/gnulib/import/m4/warn-on-use.m4 @@ -1,5 +1,5 @@ # warn-on-use.m4 serial 5 -dnl Copyright (C) 2010-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2010-2015 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. diff --git a/gdb/gnulib/import/m4/wchar_h.m4 b/gdb/gnulib/import/m4/wchar_h.m4 index c7a8b2d7818..9d1b0f8b6d2 100644 --- a/gdb/gnulib/import/m4/wchar_h.m4 +++ b/gdb/gnulib/import/m4/wchar_h.m4 @@ -1,6 +1,6 @@ dnl A placeholder for ISO C99 <wchar.h>, for platforms that have issues. -dnl Copyright (C) 2007-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2007-2015 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. diff --git a/gdb/gnulib/import/m4/wchar_t.m4 b/gdb/gnulib/import/m4/wchar_t.m4 index 534735d8c63..dc964e67e26 100644 --- a/gdb/gnulib/import/m4/wchar_t.m4 +++ b/gdb/gnulib/import/m4/wchar_t.m4 @@ -1,5 +1,5 @@ # wchar_t.m4 serial 4 (gettext-0.18.2) -dnl Copyright (C) 2002-2003, 2008-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2002-2003, 2008-2015 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. diff --git a/gdb/gnulib/import/m4/wctype_h.m4 b/gdb/gnulib/import/m4/wctype_h.m4 index 885e6fcb213..95a4705b0e7 100644 --- a/gdb/gnulib/import/m4/wctype_h.m4 +++ b/gdb/gnulib/import/m4/wctype_h.m4 @@ -2,7 +2,7 @@ dnl A placeholder for ISO C99 <wctype.h>, for platforms that lack it. -dnl Copyright (C) 2006-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2006-2015 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. diff --git a/gdb/gnulib/import/m4/wint_t.m4 b/gdb/gnulib/import/m4/wint_t.m4 index 3260cce3235..ca3fd449a14 100644 --- a/gdb/gnulib/import/m4/wint_t.m4 +++ b/gdb/gnulib/import/m4/wint_t.m4 @@ -1,5 +1,5 @@ # wint_t.m4 serial 5 (gettext-0.18.2) -dnl Copyright (C) 2003, 2007-2012 Free Software Foundation, Inc. +dnl Copyright (C) 2003, 2007-2015 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. |