diff options
author | Simon Josefsson <simon@josefsson.org> | 2008-02-25 11:19:13 +0100 |
---|---|---|
committer | Simon Josefsson <simon@josefsson.org> | 2008-02-25 11:19:13 +0100 |
commit | 6998b7925b6c317afe7b0bb583f60989314b2696 (patch) | |
tree | b49a4b0a318bd9a9e2af61459683b111984a93b0 /lgl | |
parent | 8d374aa241572fd85f16b368a4b83ba99a85b415 (diff) | |
download | gnutls-6998b7925b6c317afe7b0bb583f60989314b2696.tar.gz |
Update gnulib files.
Diffstat (limited to 'lgl')
-rw-r--r-- | lgl/Makefile.am | 2 | ||||
-rw-r--r-- | lgl/m4/time_r.m4 | 6 | ||||
-rw-r--r-- | lgl/m4/unistd_h.m4 | 6 | ||||
-rw-r--r-- | lgl/unistd.in.h | 22 |
4 files changed, 31 insertions, 5 deletions
diff --git a/lgl/Makefile.am b/lgl/Makefile.am index a545762b05..d43a4e11bd 100644 --- a/lgl/Makefile.am +++ b/lgl/Makefile.am @@ -643,6 +643,7 @@ unistd.h: unistd.in.h -e 's|@''NEXT_UNISTD_H''@|$(NEXT_UNISTD_H)|g' \ -e 's|@''GNULIB_CHOWN''@|$(GNULIB_CHOWN)|g' \ -e 's|@''GNULIB_DUP2''@|$(GNULIB_DUP2)|g' \ + -e 's|@''GNULIB_ENVIRON''@|$(GNULIB_ENVIRON)|g' \ -e 's|@''GNULIB_FCHDIR''@|$(GNULIB_FCHDIR)|g' \ -e 's|@''GNULIB_FTRUNCATE''@|$(GNULIB_FTRUNCATE)|g' \ -e 's|@''GNULIB_GETCWD''@|$(GNULIB_GETCWD)|g' \ @@ -657,6 +658,7 @@ unistd.h: unistd.in.h -e 's|@''HAVE_GETPAGESIZE''@|$(HAVE_GETPAGESIZE)|g' \ -e 's|@''HAVE_READLINK''@|$(HAVE_READLINK)|g' \ -e 's|@''HAVE_SLEEP''@|$(HAVE_SLEEP)|g' \ + -e 's|@''HAVE_DECL_ENVIRON''@|$(HAVE_DECL_ENVIRON)|g' \ -e 's|@''HAVE_DECL_GETLOGIN_R''@|$(HAVE_DECL_GETLOGIN_R)|g' \ -e 's|@''HAVE_OS_H''@|$(HAVE_OS_H)|g' \ -e 's|@''HAVE_SYS_PARAM_H''@|$(HAVE_SYS_PARAM_H)|g' \ diff --git a/lgl/m4/time_r.m4 b/lgl/m4/time_r.m4 index dbb6396607..c871b56d76 100644 --- a/lgl/m4/time_r.m4 +++ b/lgl/m4/time_r.m4 @@ -1,6 +1,6 @@ dnl Reentrant time functions like localtime_r. -dnl Copyright (C) 2003, 2006, 2007 Free Software Foundation, Inc. +dnl Copyright (C) 2003, 2006, 2007, 2008 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. @@ -23,7 +23,9 @@ AC_DEFUN([gl_TIME_R], even though the POSIX signature has the 'restrict's, since C99 says they can't affect type compatibility. */ struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r; - if (ptr) return 0;], + if (ptr) return 0; + /* Check the return type is a pointer. On HP-UX 10 it is 'int'. */ + *localtime_r (0, 0);], [gl_cv_time_r_posix=yes], [gl_cv_time_r_posix=no])]) if test $gl_cv_time_r_posix = yes; then diff --git a/lgl/m4/unistd_h.m4 b/lgl/m4/unistd_h.m4 index 4b8857ca5b..e8ccab16e8 100644 --- a/lgl/m4/unistd_h.m4 +++ b/lgl/m4/unistd_h.m4 @@ -1,5 +1,5 @@ -# unistd_h.m4 serial 10 -dnl Copyright (C) 2006-2007 Free Software Foundation, Inc. +# unistd_h.m4 serial 11 +dnl Copyright (C) 2006-2008 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. @@ -34,6 +34,7 @@ AC_DEFUN([gl_UNISTD_H_DEFAULTS], [ GNULIB_CHOWN=0; AC_SUBST([GNULIB_CHOWN]) GNULIB_DUP2=0; AC_SUBST([GNULIB_DUP2]) + GNULIB_ENVIRON=0; AC_SUBST([GNULIB_ENVIRON]) GNULIB_FCHDIR=0; AC_SUBST([GNULIB_FCHDIR]) GNULIB_FTRUNCATE=0; AC_SUBST([GNULIB_FTRUNCATE]) GNULIB_GETCWD=0; AC_SUBST([GNULIB_GETCWD]) @@ -49,6 +50,7 @@ AC_DEFUN([gl_UNISTD_H_DEFAULTS], HAVE_GETPAGESIZE=1; AC_SUBST([HAVE_GETPAGESIZE]) HAVE_READLINK=1; AC_SUBST([HAVE_READLINK]) HAVE_SLEEP=1; AC_SUBST([HAVE_SLEEP]) + HAVE_DECL_ENVIRON=1; AC_SUBST([HAVE_DECL_ENVIRON]) HAVE_DECL_GETLOGIN_R=1; AC_SUBST([HAVE_DECL_GETLOGIN_R]) HAVE_OS_H=0; AC_SUBST([HAVE_OS_H]) HAVE_SYS_PARAM_H=0; AC_SUBST([HAVE_SYS_PARAM_H]) diff --git a/lgl/unistd.in.h b/lgl/unistd.in.h index 10678f4c99..1021d4173c 100644 --- a/lgl/unistd.in.h +++ b/lgl/unistd.in.h @@ -1,5 +1,5 @@ /* Substitute for and wrapper around <unistd.h>. - Copyright (C) 2004-2007 Free Software Foundation, Inc. + Copyright (C) 2004-2008 Free Software Foundation, Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by @@ -86,6 +86,26 @@ extern int dup2 (int oldfd, int newfd); #endif +#if @GNULIB_ENVIRON@ +# if !@HAVE_DECL_ENVIRON@ +/* Set of environment variables and values. An array of strings of the form + "VARIABLE=VALUE", terminated with a NULL. */ +# if defined __APPLE__ && defined __MACH__ +# include <crt_externs.h> +# define environ (*_NSGetEnviron ()) +# else +extern char **environ; +# endif +# endif +#elif defined GNULIB_POSIXCHECK +# undef environ +# define environ \ + (GL_LINK_WARNING ("environ is unportable - " \ + "use gnulib module environ for portability"), \ + environ) +#endif + + #if @GNULIB_FCHDIR@ # if @REPLACE_FCHDIR@ |