summaryrefslogtreecommitdiff
path: root/gl
diff options
context:
space:
mode:
authorSimon Josefsson <simon@josefsson.org>2010-10-04 15:39:10 +0200
committerSimon Josefsson <simon@josefsson.org>2010-10-04 15:39:10 +0200
commitbdfcaadf62e72293e57b9cda6db3e2a0b24eb647 (patch)
tree70d64d49fe8ac182f6948301ff4e48689b001419 /gl
parentef747ffc58f3acf81dba4cb0235822cd089943bc (diff)
downloadlibtasn1-bdfcaadf62e72293e57b9cda6db3e2a0b24eb647.tar.gz
Update gnulib files.
Diffstat (limited to 'gl')
-rw-r--r--gl/Makefile.am27
-rw-r--r--gl/m4/gnulib-comp.m46
-rw-r--r--gl/m4/stdlib_h.m43
-rw-r--r--gl/m4/sys_wait_h.m433
-rw-r--r--gl/stdint.in.h5
-rw-r--r--gl/stdio.in.h3
-rw-r--r--gl/stdlib.in.h5
-rw-r--r--gl/sys_stat.in.h3
-rw-r--r--gl/sys_wait.in.h135
9 files changed, 13 insertions, 207 deletions
diff --git a/gl/Makefile.am b/gl/Makefile.am
index 574688f..11333a1 100644
--- a/gl/Makefile.am
+++ b/gl/Makefile.am
@@ -429,6 +429,7 @@ stdlib.h: stdlib.in.h $(CXXDEFS_H) $(ARG_NONNULL_H) $(WARN_ON_USE_H)
-e 's|@''GNULIB_STRTOD''@|$(GNULIB_STRTOD)|g' \
-e 's|@''GNULIB_STRTOLL''@|$(GNULIB_STRTOLL)|g' \
-e 's|@''GNULIB_STRTOULL''@|$(GNULIB_STRTOULL)|g' \
+ -e 's|@''GNULIB_SYSTEM_POSIX''@|$(GNULIB_SYSTEM_POSIX)|g' \
-e 's|@''GNULIB_UNLOCKPT''@|$(GNULIB_UNLOCKPT)|g' \
-e 's|@''GNULIB_UNSETENV''@|$(GNULIB_UNSETENV)|g' \
-e 's|@''HAVE__EXIT''@|$(HAVE__EXIT)|g' \
@@ -535,32 +536,6 @@ EXTRA_DIST += sys_stat.in.h
## end gnulib module sys_stat
-## begin gnulib module sys_wait
-
-BUILT_SOURCES += sys/wait.h
-
-# We need the following in order to create <sys/wait.h> when the system
-# has one that is incomplete.
-sys/wait.h: sys_wait.in.h $(CXXDEFS_H) $(WARN_ON_USE_H)
- $(AM_V_at)$(MKDIR_P) sys
- $(AM_V_GEN)rm -f $@-t $@ && \
- { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
- sed -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \
- -e 's|@''PRAGMA_SYSTEM_HEADER''@|@PRAGMA_SYSTEM_HEADER@|g' \
- -e 's|@''NEXT_SYS_WAIT_H''@|$(NEXT_SYS_WAIT_H)|g' \
- -e 's|@''GNULIB_WAITPID''@|$(GNULIB_WAITPID)|g' \
- -e '/definitions of _GL_FUNCDECL_RPL/r $(CXXDEFS_H)' \
- -e '/definition of _GL_WARN_ON_USE/r $(WARN_ON_USE_H)' \
- < $(srcdir)/sys_wait.in.h; \
- } > $@-t && \
- mv $@-t $@
-MOSTLYCLEANFILES += sys/wait.h sys/wait.h-t
-MOSTLYCLEANDIRS += sys
-
-EXTRA_DIST += sys_wait.in.h
-
-## end gnulib module sys_wait
-
## begin gnulib module time
BUILT_SOURCES += time.h
diff --git a/gl/m4/gnulib-comp.m4 b/gl/m4/gnulib-comp.m4
index 6eed7ff..b15340e 100644
--- a/gl/m4/gnulib-comp.m4
+++ b/gl/m4/gnulib-comp.m4
@@ -61,7 +61,6 @@ AC_DEFUN([gl_EARLY],
# Code from module stdio:
# Code from module stdlib:
# Code from module sys_stat:
- # Code from module sys_wait:
# Code from module time:
# Code from module unistd:
# Code from module update-copyright:
@@ -153,9 +152,6 @@ AC_DEFUN([gl_INIT],
# Code from module sys_stat:
gl_HEADER_SYS_STAT_H
AC_PROG_MKDIR_P
- # Code from module sys_wait:
- gl_SYS_WAIT_H
- AC_PROG_MKDIR_P
# Code from module time:
gl_HEADER_TIME_H
# Code from module unistd:
@@ -342,7 +338,6 @@ AC_DEFUN([gl_FILE_LIST], [
lib/stdio.in.h
lib/stdlib.in.h
lib/sys_stat.in.h
- lib/sys_wait.in.h
lib/time.in.h
lib/unistd.in.h
lib/version-etc-fsf.c
@@ -370,7 +365,6 @@ AC_DEFUN([gl_FILE_LIST], [
m4/stdio_h.m4
m4/stdlib_h.m4
m4/sys_stat_h.m4
- m4/sys_wait_h.m4
m4/time_h.m4
m4/unistd_h.m4
m4/valgrind-tests.m4
diff --git a/gl/m4/stdlib_h.m4 b/gl/m4/stdlib_h.m4
index fc15019..e4697ce 100644
--- a/gl/m4/stdlib_h.m4
+++ b/gl/m4/stdlib_h.m4
@@ -1,4 +1,4 @@
-# stdlib_h.m4 serial 30
+# stdlib_h.m4 serial 31
dnl Copyright (C) 2007-2010 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -73,6 +73,7 @@ AC_DEFUN([gl_STDLIB_H_DEFAULTS],
GNULIB_STRTOD=0; AC_SUBST([GNULIB_STRTOD])
GNULIB_STRTOLL=0; AC_SUBST([GNULIB_STRTOLL])
GNULIB_STRTOULL=0; AC_SUBST([GNULIB_STRTOULL])
+ GNULIB_SYSTEM_POSIX=0; AC_SUBST([GNULIB_SYSTEM_POSIX])
GNULIB_UNLOCKPT=0; AC_SUBST([GNULIB_UNLOCKPT])
GNULIB_UNSETENV=0; AC_SUBST([GNULIB_UNSETENV])
dnl Assume proper GNU behavior unless another module says otherwise.
diff --git a/gl/m4/sys_wait_h.m4 b/gl/m4/sys_wait_h.m4
deleted file mode 100644
index 63e1d21..0000000
--- a/gl/m4/sys_wait_h.m4
+++ /dev/null
@@ -1,33 +0,0 @@
-# sys_wait_h.m4 serial 5
-dnl Copyright (C) 2008-2010 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_WAIT_H],
-[
- AC_REQUIRE([gl_SYS_WAIT_H_DEFAULTS])
-
- dnl <sys/wait.h> is always overridden, because of GNULIB_POSIXCHECK.
- gl_CHECK_NEXT_HEADERS([sys/wait.h])
-
- 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([[#include <sys/wait.h>]],
- [waitpid])
-])
-
-AC_DEFUN([gl_SYS_WAIT_MODULE_INDICATOR],
-[
- dnl Use AC_REQUIRE here, so that the default settings are expanded once only.
- AC_REQUIRE([gl_SYS_WAIT_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_WAIT_H_DEFAULTS],
-[
- GNULIB_WAITPID=0; AC_SUBST([GNULIB_WAITPID])
- dnl Assume proper GNU behavior unless another module says otherwise.
-])
diff --git a/gl/stdint.in.h b/gl/stdint.in.h
index 5da5f17..7da6567 100644
--- a/gl/stdint.in.h
+++ b/gl/stdint.in.h
@@ -475,8 +475,9 @@ typedef int _verify_intmax_size[2 * (sizeof (intmax_t) == sizeof (uintmax_t)) -
/* wchar_t limits */
/* Get WCHAR_MIN, WCHAR_MAX.
- This include is not on the top, above, because on OSF/1 4.0 we have a sequence of nested
- includes <wchar.h> -> <stdio.h> -> <getopt.h> -> <stdlib.h>, and the latter includes
+ This include is not on the top, above, because on OSF/1 4.0 we have a
+ sequence of nested includes
+ <wchar.h> -> <stdio.h> -> <getopt.h> -> <stdlib.h>, and the latter includes
<stdint.h> and assumes its types are already defined. */
#if ! (defined WCHAR_MIN && defined WCHAR_MAX)
# define _GL_JUST_INCLUDE_SYSTEM_WCHAR_H
diff --git a/gl/stdio.in.h b/gl/stdio.in.h
index 80b9dbf..0bf2cc5 100644
--- a/gl/stdio.in.h
+++ b/gl/stdio.in.h
@@ -265,7 +265,8 @@ _GL_CXXALIASWARN (freopen);
#elif defined GNULIB_POSIXCHECK
# undef freopen
/* Assume freopen is always declared. */
-_GL_WARN_ON_USE (freopen, "freopen on Win32 platforms is not POSIX compatible - "
+_GL_WARN_ON_USE (freopen,
+ "freopen on Win32 platforms is not POSIX compatible - "
"use gnulib module freopen for portability");
#endif
diff --git a/gl/stdlib.in.h b/gl/stdlib.in.h
index f4309ed..10efdca 100644
--- a/gl/stdlib.in.h
+++ b/gl/stdlib.in.h
@@ -39,7 +39,7 @@
#include <stddef.h>
/* MirBSD 10 defines WEXITSTATUS in <sys/wait.h>, not in <stdlib.h>. */
-#ifndef WEXITSTATUS
+#if @GNULIB_SYSTEM_POSIX@ && !defined WEXITSTATUS
# include <sys/wait.h>
#endif
@@ -177,7 +177,8 @@ _GL_CXXALIASWARN (canonicalize_file_name);
#elif defined GNULIB_POSIXCHECK
# undef canonicalize_file_name
# if HAVE_RAW_DECL_CANONICALIZE_FILE_NAME
-_GL_WARN_ON_USE (canonicalize_file_name, "canonicalize_file_name is unportable - "
+_GL_WARN_ON_USE (canonicalize_file_name,
+ "canonicalize_file_name is unportable - "
"use gnulib module canonicalize-lgpl for portability");
# endif
#endif
diff --git a/gl/sys_stat.in.h b/gl/sys_stat.in.h
index dc7ef51..f16ccbd 100644
--- a/gl/sys_stat.in.h
+++ b/gl/sys_stat.in.h
@@ -594,7 +594,8 @@ _GL_WARN_ON_USE (mknodat, "mknodat is not portable - "
# else /* !_LARGE_FILES */
# define stat(name, st) rpl_stat (name, st)
# endif /* !_LARGE_FILES */
-_GL_EXTERN_C int stat (const char *name, struct stat *buf) _GL_ARG_NONNULL ((1, 2));
+_GL_EXTERN_C int stat (const char *name, struct stat *buf)
+ _GL_ARG_NONNULL ((1, 2));
# endif
#elif defined GNULIB_POSIXCHECK
# undef stat
diff --git a/gl/sys_wait.in.h b/gl/sys_wait.in.h
deleted file mode 100644
index 03a3b26..0000000
--- a/gl/sys_wait.in.h
+++ /dev/null
@@ -1,135 +0,0 @@
-/* A POSIX-like <sys/wait.h>.
- Copyright (C) 2001-2003, 2005-2010 Free Software Foundation, Inc.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 3, or (at your option)
- any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software Foundation,
- Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */
-
-
-#ifndef _GL_SYS_WAIT_H
-
-#if __GNUC__ >= 3
-@PRAGMA_SYSTEM_HEADER@
-#endif
-
-/* The include_next requires a split double-inclusion guard. */
-#if !((defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__)
-# @INCLUDE_NEXT@ @NEXT_SYS_WAIT_H@
-#endif
-
-#ifndef _GL_SYS_WAIT_H
-#define _GL_SYS_WAIT_H
-
-/* Get pid_t. */
-#include <sys/types.h>
-
-
-/* The definitions of _GL_FUNCDECL_RPL etc. are copied here. */
-
-/* The definition of _GL_WARN_ON_USE is copied here. */
-
-
-#if !((defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__)
-/* Unix API. */
-
-/* The following macros apply to an argument x, that is a status of a process,
- as returned by waitpid().
- On nearly all systems, including Linux/x86, WEXITSTATUS are bits 15..8 and
- WTERMSIG are bits 7..0, while BeOS uses the opposite. Therefore programs
- have to use the abstract macros. */
-
-/* For valid x, exactly one of WIFSIGNALED(x), WIFEXITED(x), WIFSTOPPED(x)
- is true. */
-# ifndef WIFSIGNALED
-# define WIFSIGNALED(x) (WTERMSIG (x) != 0 && WTERMSIG(x) != 0x7f)
-# endif
-# ifndef WIFEXITED
-# define WIFEXITED(x) (WTERMSIG (x) == 0)
-# endif
-# ifndef WIFSTOPPED
-# define WIFSTOPPED(x) (WTERMSIG (x) == 0x7f)
-# endif
-
-/* The termination signal. Only to be accessed if WIFSIGNALED(x) is true. */
-# ifndef WTERMSIG
-# define WTERMSIG(x) ((x) & 0x7f)
-# endif
-
-/* The exit status. Only to be accessed if WIFEXITED(x) is true. */
-# ifndef WEXITSTATUS
-# define WEXITSTATUS(x) (((x) >> 8) & 0xff)
-# endif
-
-/* The stopping signal. Only to be accessed if WIFSTOPPED(x) is true. */
-# ifndef WSTOPSIG
-# define WSTOPSIG(x) (((x) >> 8) & 0x7f)
-# endif
-
-/* True if the process dumped core. Not standardized by POSIX. */
-# ifndef WCOREDUMP
-# define WCOREDUMP(x) ((x) & 0x80)
-# endif
-
-#else
-/* Native Windows API. */
-
-# include <signal.h> /* for SIGTERM */
-
-/* The following macros apply to an argument x, that is a status of a process,
- as returned by waitpid() or, equivalently, _cwait() or GetExitCodeProcess().
- This value is simply an 'int', not composed of bit fields. */
-
-/* When an unhandled fatal signal terminates a process, the exit code is 3. */
-# define WIFSIGNALED(x) ((x) == 3)
-# define WIFEXITED(x) ((x) != 3)
-# define WIFSTOPPED(x) 0
-
-/* The signal that terminated a process is not known posthum. */
-# define WTERMSIG(x) SIGTERM
-
-# define WEXITSTATUS(x) (x)
-
-/* There are no stopping signals. */
-# define WSTOPSIG(x) 0
-
-/* There are no core dumps. */
-# define WCOREDUMP(x) 0
-
-#endif
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/* Declarations of functions. */
-
-#if @GNULIB_WAITPID@
-# if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
-_GL_FUNCDECL_SYS (waitpid, pid_t, (pid_t pid, int *statusp, int options));
-# endif
-_GL_CXXALIAS_SYS (waitpid, pid_t, (pid_t pid, int *statusp, int options));
-_GL_CXXALIASWARN (waitpid);
-#elif defined GNULIB_POSIXCHECK
-# undef waitpid
-# if HAVE_RAW_DECL_WAITPID
-_GL_WARN_ON_USE (waitpid, "waitpid is unportable - "
- "use gnulib module sys_wait for portability");
-# endif
-#endif
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* _GL_SYS_WAIT_H */
-#endif /* _GL_SYS_WAIT_H */