summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNikos Mavrogiannopoulos <nmav@crystal.(none)>2007-09-17 11:58:32 +0300
committerNikos Mavrogiannopoulos <nmav@crystal.(none)>2007-09-17 11:58:32 +0300
commit4f653a599cfb6a71b76c1228ba614a0cfdec87f7 (patch)
tree0d0bf1aeabfac4c57d1dd818efbb5cdcebaccb7e
parent9afa028dae6756ef463652e56543c89b04add024 (diff)
parentf847a4672cdde344c9d258811f509bc7ff7e0e09 (diff)
downloadgnutls-4f653a599cfb6a71b76c1228ba614a0cfdec87f7.tar.gz
Merge branch 'master' of git://repo.or.cz/gnutls
-rw-r--r--.cvsignore22
-rw-r--r--NEWS15
-rw-r--r--build-aux/.cvsignore8
-rw-r--r--configure.in4
-rw-r--r--doc/.cvsignore27
-rw-r--r--doc/examples/.cvsignore27
-rw-r--r--doc/examples/Makefile.am3
-rw-r--r--doc/manpages/.cvsignore3
-rw-r--r--doc/reference/.cvsignore24
-rw-r--r--doc/reference/tmpl/.cvsignore9
-rw-r--r--doc/scripts/.cvsignore2
-rw-r--r--gl/.cvsignore11
-rw-r--r--gl/gettext.h270
-rw-r--r--gl/gnulib.mk220
-rw-r--r--gl/m4/extensions.m458
-rw-r--r--gl/m4/gnulib-cache.m44
-rw-r--r--gl/m4/gnulib-comp.m423
-rw-r--r--gl/m4/sockpfaf.m458
-rw-r--r--gl/m4/stdbool.m4115
-rw-r--r--gl/m4/stdio_h.m482
-rw-r--r--gl/m4/string_h.m477
-rw-r--r--gl/m4/sys_socket_h.m451
-rw-r--r--gl/m4/unistd_h.m456
-rw-r--r--gl/stdbool_.h118
-rw-r--r--gl/stdio_.h353
-rw-r--r--gl/string_.h548
-rw-r--r--gl/sys_socket_.h91
-rw-r--r--gl/unistd_.h262
-rw-r--r--guile/src/core.c3
-rw-r--r--includes/.cvsignore2
-rw-r--r--includes/gnutls/.cvsignore3
-rw-r--r--lgl/.cvsignore23
-rw-r--r--lgl/Makefile.am51
-rw-r--r--lgl/m4/absolute-header.m449
-rw-r--r--lgl/m4/gnulib-comp.m49
-rw-r--r--lgl/m4/malloc.m441
-rw-r--r--lgl/m4/realloc.m423
-rw-r--r--lgl/m4/stdlib_h.m435
-rw-r--r--lgl/m4/time_h.m42
-rw-r--r--lgl/realloc.c65
-rw-r--r--lgl/stdlib_.h177
-rw-r--r--lib/.cvsignore21
-rw-r--r--lib/gnutls_algorithms.c21
-rw-r--r--lib/gnutls_int.h2
-rw-r--r--lib/minitasn1/.cvsignore7
-rw-r--r--lib/x509/.cvsignore15
-rw-r--r--libextra/.cvsignore12
-rw-r--r--libextra/minilzo/.cvsignore7
-rw-r--r--libextra/opencdk/.cvsignore6
-rw-r--r--libextra/openpgp/.cvsignore11
-rw-r--r--m4/.cvsignore33
-rw-r--r--po/.cvsignore20
-rw-r--r--src/.cvsignore21
-rw-r--r--src/cfg/.cvsignore2
-rw-r--r--src/cfg/platon/.cvsignore2
-rw-r--r--src/cfg/platon/str/.cvsignore2
-rw-r--r--src/openpgp/.cvsignore2
-rw-r--r--src/srp/.cvsignore4
-rw-r--r--src/x509/.cvsignore4
-rw-r--r--tests/.cvsignore18
-rw-r--r--tests/hostname-check/.cvsignore5
-rw-r--r--tests/key-id/.cvsignore2
-rw-r--r--tests/nist-pkits/.cvsignore10
-rw-r--r--tests/pathlen/.cvsignore2
-rw-r--r--tests/pkcs1-padding/.cvsignore2
-rw-r--r--tests/pkcs12-decode/.cvsignore2
-rw-r--r--tests/pkcs8-decode/.cvsignore2
-rw-r--r--tests/rsa-md5-collision/.cvsignore2
-rw-r--r--tests/sha2/.cvsignore2
-rw-r--r--tests/userid/.cvsignore2
-rw-r--r--tests/x509paths/.cvsignore2
71 files changed, 486 insertions, 2781 deletions
diff --git a/.cvsignore b/.cvsignore
deleted file mode 100644
index ec81bcd518..0000000000
--- a/.cvsignore
+++ /dev/null
@@ -1,22 +0,0 @@
-ABOUT-NLS
-aclocal.m4
-autom4te.cache
-ChangeLog
-ChangeLog.bak
-config.cache
-config.h
-config.h.in
-config.log
-config.rpath
-config.status
-configure
-.cvsignore
-.cvsusers
-gnutls*.tar.*
-INSTALL
-libtool
-ltconfig
-Makefile
-Makefile.in
-mkinstalldirs
-stamp-*
diff --git a/NEWS b/NEWS
index a5520f8956..adad17b64c 100644
--- a/NEWS
+++ b/NEWS
@@ -3,6 +3,18 @@ Copyright (C) 2004, 2005, 2006, 2007 Simon Josefsson
Copyright (C) 2000, 2001, 2002, 2003, 2004 Nikos Mavroyanopoulos
See the end for copying conditions.
+* Version 2.0.1 (unreleased)
+
+** Update SRP extension type and cipher suite with official IANA values.
+This breaks backwards compatibility with SRP in older versions of
+GnuTLS, but this is intentional to speed up the adoption of the
+official values. The old values we used were incorrect.
+
+** Guile: Fix `x509-certificate-dn-oid'
+
+** API and ABI modifications:
+No changes since last version.
+
* Version 2.0.0 (released 2007-09-04)
** Included copy of Libtasn1 upgraded to version 1.1.
@@ -11,6 +23,9 @@ See the end for copying conditions.
** Don't build examples for disabled features.
+** API and ABI modifications:
+No changes since last version.
+
* Version 1.7.19 (released 2007-08-27)
** Fix gnutls_error_is_fatal so that positive "errors" are non-critical.
diff --git a/build-aux/.cvsignore b/build-aux/.cvsignore
deleted file mode 100644
index 19cdb3bac7..0000000000
--- a/build-aux/.cvsignore
+++ /dev/null
@@ -1,8 +0,0 @@
-config.guess
-config.sub
-depcomp
-install-sh
-ltmain.sh
-mdate-sh
-missing
-texinfo.tex
diff --git a/configure.in b/configure.in
index f6a7c3435c..302d34e179 100644
--- a/configure.in
+++ b/configure.in
@@ -21,7 +21,7 @@ dnl Process this file with autoconf to produce a configure script.
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
AC_PREREQ(2.61)
-AC_INIT([GnuTLS], [2.0.0], [bug-gnutls@gnu.org])
+AC_INIT([GnuTLS], [2.0.1], [bug-gnutls@gnu.org])
AC_CONFIG_AUX_DIR([build-aux])
AC_CANONICAL_TARGET
@@ -36,7 +36,7 @@ AB_INIT
# Interfaces added: AGE++
# Interfaces removed: AGE=0
AC_SUBST(LT_CURRENT, 21)
-AC_SUBST(LT_REVISION, 3)
+AC_SUBST(LT_REVISION, 4)
AC_SUBST(LT_AGE, 8)
ac_full=1
diff --git a/doc/.cvsignore b/doc/.cvsignore
deleted file mode 100644
index e62007d216..0000000000
--- a/doc/.cvsignore
+++ /dev/null
@@ -1,27 +0,0 @@
-Makefile.in
-Makefile
-.cvsignore
-error_codes.texi
-gnutls.aux
-gnutls.cp
-gnutls.cps
-gnutls.dvi
-gnutls.fn
-gnutls.info*
-gnutls.ky
-gnutls.log
-gnutls.pg
-gnutls.ps
-gnutls.toc
-gnutls.tp
-gnutls.vr
-version.texi
-stamp-*
-gnutls-api.texi
-gnutls-extra-api.texi
-gnutls.html
-gnutls.fns
-gnutls.pdf
-ia-api.texi
-pgp-api.texi
-x509-api.texi
diff --git a/doc/examples/.cvsignore b/doc/examples/.cvsignore
deleted file mode 100644
index fe99cf22ce..0000000000
--- a/doc/examples/.cvsignore
+++ /dev/null
@@ -1,27 +0,0 @@
-.deps
-.libs
-Makefile
-Makefile.in
-ex-alert.lo
-ex-cert-select
-ex-client-authz
-ex-client-resume
-ex-client-srp
-ex-client-tlsia
-ex-client1
-ex-client2
-ex-crq
-ex-pkcs12.lo
-ex-rfc2818.lo
-ex-serv-anon
-ex-serv-authz
-ex-serv-export
-ex-serv-pgp
-ex-serv-srp
-ex-serv1
-ex-session-info.lo
-ex-verify.lo
-ex-x509-info.lo
-libexamples.la
-tcp.c
-tcp.lo
diff --git a/doc/examples/Makefile.am b/doc/examples/Makefile.am
index be25ec42ec..3d2b6223d3 100644
--- a/doc/examples/Makefile.am
+++ b/doc/examples/Makefile.am
@@ -28,10 +28,11 @@ LDADD = libexamples.la \
../../libextra/libgnutls-extra.la
noinst_PROGRAMS = ex-cert-select ex-client2 ex-client-resume \
- ex-client-tlsia ex-crq ex-serv1 ex-serv-export
+ ex-crq ex-serv1 ex-serv-export
if ENABLE_ANON
noinst_PROGRAMS += ex-client1 ex-serv-anon
+noinst_PROGRAMS += ex-client-tlsia
endif
if ENABLE_OPENPGP
diff --git a/doc/manpages/.cvsignore b/doc/manpages/.cvsignore
deleted file mode 100644
index d5de058e71..0000000000
--- a/doc/manpages/.cvsignore
+++ /dev/null
@@ -1,3 +0,0 @@
-Makefile
-Makefile.in
-*.3
diff --git a/doc/reference/.cvsignore b/doc/reference/.cvsignore
deleted file mode 100644
index dfb1159d18..0000000000
--- a/doc/reference/.cvsignore
+++ /dev/null
@@ -1,24 +0,0 @@
-Makefile
-Makefile.in
-gnutls-decl-list.txt
-gnutls-decl.txt
-gnutls-overrides.txt
-gnutls-sections.txt
-gnutls-undocumented.txt
-gnutls-unused.txt
-gnutls.args
-gnutls.hierarchy
-gnutls.interfaces
-gnutls.prerequisites
-gnutls.signals
-gnutls.types
-html
-html-build.stamp
-html.stamp
-scan-build.stamp
-sgml-build.stamp
-sgml.stamp
-tmpl
-tmpl-build.stamp
-tmpl.stamp
-xml
diff --git a/doc/reference/tmpl/.cvsignore b/doc/reference/tmpl/.cvsignore
deleted file mode 100644
index e23371f4b6..0000000000
--- a/doc/reference/tmpl/.cvsignore
+++ /dev/null
@@ -1,9 +0,0 @@
-extra.sgml
-gnutls.sgml
-libtasn1.sgml
-lzodefs.sgml
-opencdk.sgml
-openpgp.sgml
-openssl.sgml
-pkcs12.sgml
-x509.sgml
diff --git a/doc/scripts/.cvsignore b/doc/scripts/.cvsignore
deleted file mode 100644
index 282522db03..0000000000
--- a/doc/scripts/.cvsignore
+++ /dev/null
@@ -1,2 +0,0 @@
-Makefile
-Makefile.in
diff --git a/gl/.cvsignore b/gl/.cvsignore
deleted file mode 100644
index a7b3accf49..0000000000
--- a/gl/.cvsignore
+++ /dev/null
@@ -1,11 +0,0 @@
-.deps
-.libs
-Makefile
-Makefile.in
-alloca.h
-libgnu.la
-*.lo
-sys
-arpa
-stdint.h
-string.h
diff --git a/gl/gettext.h b/gl/gettext.h
deleted file mode 100644
index 9d76ec9afc..0000000000
--- a/gl/gettext.h
+++ /dev/null
@@ -1,270 +0,0 @@
-/* Convenience header for conditional use of GNU <libintl.h>.
- Copyright (C) 1995-1998, 2000-2002, 2004-2006 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 2, 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 _LIBGETTEXT_H
-#define _LIBGETTEXT_H 1
-
-/* NLS can be disabled through the configure --disable-nls option. */
-#if ENABLE_NLS
-
-/* Get declarations of GNU message catalog functions. */
-# include <libintl.h>
-
-/* You can set the DEFAULT_TEXT_DOMAIN macro to specify the domain used by
- the gettext() and ngettext() macros. This is an alternative to calling
- textdomain(), and is useful for libraries. */
-# ifdef DEFAULT_TEXT_DOMAIN
-# undef gettext
-# define gettext(Msgid) \
- dgettext (DEFAULT_TEXT_DOMAIN, Msgid)
-# undef ngettext
-# define ngettext(Msgid1, Msgid2, N) \
- dngettext (DEFAULT_TEXT_DOMAIN, Msgid1, Msgid2, N)
-# endif
-
-#else
-
-/* Solaris /usr/include/locale.h includes /usr/include/libintl.h, which
- chokes if dcgettext is defined as a macro. So include it now, to make
- later inclusions of <locale.h> a NOP. We don't include <libintl.h>
- as well because people using "gettext.h" will not include <libintl.h>,
- and also including <libintl.h> would fail on SunOS 4, whereas <locale.h>
- is OK. */
-#if defined(__sun)
-# include <locale.h>
-#endif
-
-/* Many header files from the libstdc++ coming with g++ 3.3 or newer include
- <libintl.h>, which chokes if dcgettext is defined as a macro. So include
- it now, to make later inclusions of <libintl.h> a NOP. */
-#if defined(__cplusplus) && defined(__GNUG__) && (__GNUC__ >= 3)
-# include <cstdlib>
-# if (__GLIBC__ >= 2) || _GLIBCXX_HAVE_LIBINTL_H
-# include <libintl.h>
-# endif
-#endif
-
-/* Disabled NLS.
- The casts to 'const char *' serve the purpose of producing warnings
- for invalid uses of the value returned from these functions.
- On pre-ANSI systems without 'const', the config.h file is supposed to
- contain "#define const". */
-# define gettext(Msgid) ((const char *) (Msgid))
-# define dgettext(Domainname, Msgid) ((void) (Domainname), gettext (Msgid))
-# define dcgettext(Domainname, Msgid, Category) \
- ((void) (Category), dgettext (Domainname, Msgid))
-# define ngettext(Msgid1, Msgid2, N) \
- ((N) == 1 \
- ? ((void) (Msgid2), (const char *) (Msgid1)) \
- : ((void) (Msgid1), (const char *) (Msgid2)))
-# define dngettext(Domainname, Msgid1, Msgid2, N) \
- ((void) (Domainname), ngettext (Msgid1, Msgid2, N))
-# define dcngettext(Domainname, Msgid1, Msgid2, N, Category) \
- ((void) (Category), dngettext(Domainname, Msgid1, Msgid2, N))
-# define textdomain(Domainname) ((const char *) (Domainname))
-# define bindtextdomain(Domainname, Dirname) \
- ((void) (Domainname), (const char *) (Dirname))
-# define bind_textdomain_codeset(Domainname, Codeset) \
- ((void) (Domainname), (const char *) (Codeset))
-
-#endif
-
-/* A pseudo function call that serves as a marker for the automated
- extraction of messages, but does not call gettext(). The run-time
- translation is done at a different place in the code.
- The argument, String, should be a literal string. Concatenated strings
- and other string expressions won't work.
- The macro's expansion is not parenthesized, so that it is suitable as
- initializer for static 'char[]' or 'const char[]' variables. */
-#define gettext_noop(String) String
-
-/* The separator between msgctxt and msgid in a .mo file. */
-#define GETTEXT_CONTEXT_GLUE "\004"
-
-/* Pseudo function calls, taking a MSGCTXT and a MSGID instead of just a
- MSGID. MSGCTXT and MSGID must be string literals. MSGCTXT should be
- short and rarely need to change.
- The letter 'p' stands for 'particular' or 'special'. */
-#ifdef DEFAULT_TEXT_DOMAIN
-# define pgettext(Msgctxt, Msgid) \
- pgettext_aux (DEFAULT_TEXT_DOMAIN, Msgctxt GETTEXT_CONTEXT_GLUE Msgid, Msgid, LC_MESSAGES)
-#else
-# define pgettext(Msgctxt, Msgid) \
- pgettext_aux (NULL, Msgctxt GETTEXT_CONTEXT_GLUE Msgid, Msgid, LC_MESSAGES)
-#endif
-#define dpgettext(Domainname, Msgctxt, Msgid) \
- pgettext_aux (Domainname, Msgctxt GETTEXT_CONTEXT_GLUE Msgid, Msgid, LC_MESSAGES)
-#define dcpgettext(Domainname, Msgctxt, Msgid, Category) \
- pgettext_aux (Domainname, Msgctxt GETTEXT_CONTEXT_GLUE Msgid, Msgid, Category)
-#ifdef DEFAULT_TEXT_DOMAIN
-# define npgettext(Msgctxt, Msgid, MsgidPlural, N) \
- npgettext_aux (DEFAULT_TEXT_DOMAIN, Msgctxt GETTEXT_CONTEXT_GLUE Msgid, Msgid, MsgidPlural, N, LC_MESSAGES)
-#else
-# define npgettext(Msgctxt, Msgid, MsgidPlural, N) \
- npgettext_aux (NULL, Msgctxt GETTEXT_CONTEXT_GLUE Msgid, Msgid, MsgidPlural, N, LC_MESSAGES)
-#endif
-#define dnpgettext(Domainname, Msgctxt, Msgid, MsgidPlural, N) \
- npgettext_aux (Domainname, Msgctxt GETTEXT_CONTEXT_GLUE Msgid, Msgid, MsgidPlural, N, LC_MESSAGES)
-#define dcnpgettext(Domainname, Msgctxt, Msgid, MsgidPlural, N, Category) \
- npgettext_aux (Domainname, Msgctxt GETTEXT_CONTEXT_GLUE Msgid, Msgid, MsgidPlural, N, Category)
-
-#ifdef __GNUC__
-__inline
-#else
-#ifdef __cplusplus
-inline
-#endif
-#endif
-static const char *
-pgettext_aux (const char *domain,
- const char *msg_ctxt_id, const char *msgid,
- int category)
-{
- const char *translation = dcgettext (domain, msg_ctxt_id, category);
- if (translation == msg_ctxt_id)
- return msgid;
- else
- return translation;
-}
-
-#ifdef __GNUC__
-__inline
-#else
-#ifdef __cplusplus
-inline
-#endif
-#endif
-static const char *
-npgettext_aux (const char *domain,
- const char *msg_ctxt_id, const char *msgid,
- const char *msgid_plural, unsigned long int n,
- int category)
-{
- const char *translation =
- dcngettext (domain, msg_ctxt_id, msgid_plural, n, category);
- if (translation == msg_ctxt_id || translation == msgid_plural)
- return (n == 1 ? msgid : msgid_plural);
- else
- return translation;
-}
-
-/* The same thing extended for non-constant arguments. Here MSGCTXT and MSGID
- can be arbitrary expressions. But for string literals these macros are
- less efficient than those above. */
-
-#include <string.h>
-
-#define _LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS \
- (((__GNUC__ >= 3 || __GNUG__ >= 2) && !__STRICT_ANSI__) \
- /* || __STDC_VERSION__ >= 199901L */ )
-
-#if !_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS
-#include <stdlib.h>
-#endif
-
-#define pgettext_expr(Msgctxt, Msgid) \
- dcpgettext_expr (NULL, Msgctxt, Msgid, LC_MESSAGES)
-#define dpgettext_expr(Domainname, Msgctxt, Msgid) \
- dcpgettext_expr (Domainname, Msgctxt, Msgid, LC_MESSAGES)
-
-#ifdef __GNUC__
-__inline
-#else
-#ifdef __cplusplus
-inline
-#endif
-#endif
-static const char *
-dcpgettext_expr (const char *domain,
- const char *msgctxt, const char *msgid,
- int category)
-{
- size_t msgctxt_len = strlen (msgctxt) + 1;
- size_t msgid_len = strlen (msgid) + 1;
- const char *translation;
-#if _LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS
- char msg_ctxt_id[msgctxt_len + msgid_len];
-#else
- char buf[1024];
- char *msg_ctxt_id =
- (msgctxt_len + msgid_len <= sizeof (buf)
- ? buf
- : (char *) malloc (msgctxt_len + msgid_len));
- if (msg_ctxt_id != NULL)
-#endif
- {
- memcpy (msg_ctxt_id, msgctxt, msgctxt_len - 1);
- msg_ctxt_id[msgctxt_len - 1] = '\004';
- memcpy (msg_ctxt_id + msgctxt_len, msgid, msgid_len);
- translation = dcgettext (domain, msg_ctxt_id, category);
-#if !_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS
- if (msg_ctxt_id != buf)
- free (msg_ctxt_id);
-#endif
- if (translation != msg_ctxt_id)
- return translation;
- }
- return msgid;
-}
-
-#define npgettext_expr(Msgctxt, Msgid, MsgidPlural, N) \
- dcnpgettext_expr (NULL, Msgctxt, Msgid, MsgidPlural, N, LC_MESSAGES)
-#define dnpgettext_expr(Domainname, Msgctxt, Msgid, MsgidPlural, N) \
- dcnpgettext_expr (Domainname, Msgctxt, Msgid, MsgidPlural, N, LC_MESSAGES)
-
-#ifdef __GNUC__
-__inline
-#else
-#ifdef __cplusplus
-inline
-#endif
-#endif
-static const char *
-dcnpgettext_expr (const char *domain,
- const char *msgctxt, const char *msgid,
- const char *msgid_plural, unsigned long int n,
- int category)
-{
- size_t msgctxt_len = strlen (msgctxt) + 1;
- size_t msgid_len = strlen (msgid) + 1;
- const char *translation;
-#if _LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS
- char msg_ctxt_id[msgctxt_len + msgid_len];
-#else
- char buf[1024];
- char *msg_ctxt_id =
- (msgctxt_len + msgid_len <= sizeof (buf)
- ? buf
- : (char *) malloc (msgctxt_len + msgid_len));
- if (msg_ctxt_id != NULL)
-#endif
- {
- memcpy (msg_ctxt_id, msgctxt, msgctxt_len - 1);
- msg_ctxt_id[msgctxt_len - 1] = '\004';
- memcpy (msg_ctxt_id + msgctxt_len, msgid, msgid_len);
- translation = dcngettext (domain, msg_ctxt_id, msgid_plural, n, category);
-#if !_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS
- if (msg_ctxt_id != buf)
- free (msg_ctxt_id);
-#endif
- if (!(translation == msg_ctxt_id || translation == msgid_plural))
- return translation;
- }
- return (n == 1 ? msgid : msgid_plural);
-}
-
-#endif /* _LIBGETTEXT_H */
diff --git a/gl/gnulib.mk b/gl/gnulib.mk
index 640d7a10bf..f727afe883 100644
--- a/gl/gnulib.mk
+++ b/gl/gnulib.mk
@@ -9,7 +9,7 @@
# the same distribution terms as the rest of that program.
#
# Generated by gnulib-tool.
-# Reproduce by: gnulib-tool --import --dir=. --local-dir=gl/override --lib=libgnu --source-base=gl --m4-base=gl/m4 --doc-base=doc --aux-dir=build-aux --avoid=snprintf --avoid=vasnprintf --makefile-name=gnulib.mk --libtool --macro-prefix=gl arpa_inet error fdl gendocs getaddrinfo getline getpass gpl-2.0 inet_ntop inet_pton lgpl-2.1 maintainer-makefile progname readline version-etc-fsf
+# Reproduce by: gnulib-tool --import --dir=. --local-dir=gl/override --lib=libgnu --source-base=gl --m4-base=gl/m4 --doc-base=doc --aux-dir=build-aux --avoid=gettext-h --avoid=malloc-posix --avoid=realloc-posix --avoid=snprintf --avoid=stdbool --avoid=stdio --avoid=string --avoid=sys_socket --avoid=unistd --avoid=vasnprintf --makefile-name=gnulib.mk --libtool --macro-prefix=gl arpa_inet error fdl gendocs getaddrinfo getline getpass gpl-2.0 inet_ntop inet_pton lgpl-2.1 maintainer-makefile progname readline version-etc-fsf
MOSTLYCLEANFILES += core *.stackdump
@@ -101,12 +101,6 @@ EXTRA_libgnu_la_SOURCES += getpass.c
## end gnulib module getpass
-## begin gnulib module gettext-h
-
-libgnu_la_SOURCES += gettext.h
-
-## end gnulib module gettext-h
-
## begin gnulib module havelib
@@ -132,14 +126,6 @@ EXTRA_libgnu_la_SOURCES += inet_pton.c
## end gnulib module inet_pton
-## begin gnulib module link-warning
-
-LINK_WARNING_H=$(top_srcdir)/build-aux/link-warning.h
-
-EXTRA_DIST += $(top_srcdir)/build-aux/link-warning.h
-
-## end gnulib module link-warning
-
## begin gnulib module lseek
@@ -193,81 +179,6 @@ EXTRA_libgnu_la_SOURCES += readline.c
## end gnulib module readline
-## begin gnulib module stdbool
-
-BUILT_SOURCES += $(STDBOOL_H)
-
-# We need the following in order to create <stdbool.h> when the system
-# doesn't have one that works.
-stdbool.h: stdbool_.h
- rm -f $@-t $@
- { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
- sed -e 's/@''HAVE__BOOL''@/$(HAVE__BOOL)/g' < $(srcdir)/stdbool_.h; \
- } > $@-t
- mv $@-t $@
-MOSTLYCLEANFILES += stdbool.h stdbool.h-t
-
-EXTRA_DIST += stdbool_.h
-
-## end gnulib module stdbool
-
-## begin gnulib module stdio
-
-BUILT_SOURCES += stdio.h
-
-# We need the following in order to create <stdio.h> when the system
-# doesn't have one that works with the given compiler.
-stdio.h: stdio_.h
- rm -f $@-t $@
- { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \
- sed -e 's/@''INCLUDE_NEXT''@/$(INCLUDE_NEXT)/g' \
- -e 's|@''NEXT_STDIO_H''@|$(NEXT_STDIO_H)|g' \
- -e 's|@''GNULIB_FPRINTF_POSIX''@|$(GNULIB_FPRINTF_POSIX)|g' \
- -e 's|@''GNULIB_PRINTF_POSIX''@|$(GNULIB_PRINTF_POSIX)|g' \
- -e 's|@''GNULIB_SNPRINTF''@|$(GNULIB_SNPRINTF)|g' \
- -e 's|@''GNULIB_SPRINTF_POSIX''@|$(GNULIB_SPRINTF_POSIX)|g' \
- -e 's|@''GNULIB_VFPRINTF_POSIX''@|$(GNULIB_VFPRINTF_POSIX)|g' \
- -e 's|@''GNULIB_VPRINTF_POSIX''@|$(GNULIB_VPRINTF_POSIX)|g' \
- -e 's|@''GNULIB_VSNPRINTF''@|$(GNULIB_VSNPRINTF)|g' \
- -e 's|@''GNULIB_VSPRINTF_POSIX''@|$(GNULIB_VSPRINTF_POSIX)|g' \
- -e 's|@''GNULIB_VASPRINTF''@|$(GNULIB_VASPRINTF)|g' \
- -e 's|@''GNULIB_FSEEK''@|$(GNULIB_FSEEK)|g' \
- -e 's|@''GNULIB_FSEEKO''@|$(GNULIB_FSEEKO)|g' \
- -e 's|@''GNULIB_FTELL''@|$(GNULIB_FTELL)|g' \
- -e 's|@''GNULIB_FTELLO''@|$(GNULIB_FTELLO)|g' \
- -e 's|@''GNULIB_FFLUSH''@|$(GNULIB_FFLUSH)|g' \
- -e 's|@''GNULIB_GETDELIM''@|$(GNULIB_GETDELIM)|g' \
- -e 's|@''GNULIB_GETLINE''@|$(GNULIB_GETLINE)|g' \
- -e 's|@''REPLACE_FPRINTF''@|$(REPLACE_FPRINTF)|g' \
- -e 's|@''REPLACE_VFPRINTF''@|$(REPLACE_VFPRINTF)|g' \
- -e 's|@''REPLACE_PRINTF''@|$(REPLACE_PRINTF)|g' \
- -e 's|@''REPLACE_VPRINTF''@|$(REPLACE_VPRINTF)|g' \
- -e 's|@''REPLACE_SNPRINTF''@|$(REPLACE_SNPRINTF)|g' \
- -e 's|@''HAVE_DECL_SNPRINTF''@|$(HAVE_DECL_SNPRINTF)|g' \
- -e 's|@''REPLACE_VSNPRINTF''@|$(REPLACE_VSNPRINTF)|g' \
- -e 's|@''HAVE_DECL_VSNPRINTF''@|$(HAVE_DECL_VSNPRINTF)|g' \
- -e 's|@''REPLACE_SPRINTF''@|$(REPLACE_SPRINTF)|g' \
- -e 's|@''REPLACE_VSPRINTF''@|$(REPLACE_VSPRINTF)|g' \
- -e 's|@''HAVE_VASPRINTF''@|$(HAVE_VASPRINTF)|g' \
- -e 's|@''REPLACE_VASPRINTF''@|$(REPLACE_VASPRINTF)|g' \
- -e 's|@''REPLACE_FSEEKO''@|$(REPLACE_FSEEKO)|g' \
- -e 's|@''REPLACE_FSEEK''@|$(REPLACE_FSEEK)|g' \
- -e 's|@''REPLACE_FTELLO''@|$(REPLACE_FTELLO)|g' \
- -e 's|@''REPLACE_FTELL''@|$(REPLACE_FTELL)|g' \
- -e 's|@''REPLACE_FFLUSH''@|$(REPLACE_FFLUSH)|g' \
- -e 's|@''HAVE_DECL_GETDELIM''@|$(HAVE_DECL_GETDELIM)|g' \
- -e 's|@''HAVE_DECL_GETLINE''@|$(HAVE_DECL_GETLINE)|g' \
- -e 's|@''REPLACE_GETLINE''@|$(REPLACE_GETLINE)|g' \
- -e '/definition of GL_LINK_WARNING/r $(LINK_WARNING_H)' \
- < $(srcdir)/stdio_.h; \
- } > $@-t
- mv $@-t $@
-MOSTLYCLEANFILES += stdio.h stdio.h-t
-
-EXTRA_DIST += stdio_.h
-
-## end gnulib module stdio
-
## begin gnulib module strdup
@@ -277,135 +188,6 @@ EXTRA_libgnu_la_SOURCES += strdup.c
## end gnulib module strdup
-## begin gnulib module string
-
-BUILT_SOURCES += string.h
-
-# We need the following in order to create <string.h> when the system
-# doesn't have one that works with the given compiler.
-string.h: string_.h
- rm -f $@-t $@
- { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \
- sed -e 's/@''INCLUDE_NEXT''@/$(INCLUDE_NEXT)/g' \
- -e 's|@''NEXT_STRING_H''@|$(NEXT_STRING_H)|g' \
- -e 's|@''GNULIB_MBSLEN''@|$(GNULIB_MBSLEN)|g' \
- -e 's|@''GNULIB_MBSNLEN''@|$(GNULIB_MBSNLEN)|g' \
- -e 's|@''GNULIB_MBSCHR''@|$(GNULIB_MBSCHR)|g' \
- -e 's|@''GNULIB_MBSRCHR''@|$(GNULIB_MBSRCHR)|g' \
- -e 's|@''GNULIB_MBSSTR''@|$(GNULIB_MBSSTR)|g' \
- -e 's|@''GNULIB_MBSCASECMP''@|$(GNULIB_MBSCASECMP)|g' \
- -e 's|@''GNULIB_MBSNCASECMP''@|$(GNULIB_MBSNCASECMP)|g' \
- -e 's|@''GNULIB_MBSPCASECMP''@|$(GNULIB_MBSPCASECMP)|g' \
- -e 's|@''GNULIB_MBSCASESTR''@|$(GNULIB_MBSCASESTR)|g' \
- -e 's|@''GNULIB_MBSCSPN''@|$(GNULIB_MBSCSPN)|g' \
- -e 's|@''GNULIB_MBSPBRK''@|$(GNULIB_MBSPBRK)|g' \
- -e 's|@''GNULIB_MBSSPN''@|$(GNULIB_MBSSPN)|g' \
- -e 's|@''GNULIB_MBSSEP''@|$(GNULIB_MBSSEP)|g' \
- -e 's|@''GNULIB_MBSTOK_R''@|$(GNULIB_MBSTOK_R)|g' \
- -e 's|@''GNULIB_MEMMEM''@|$(GNULIB_MEMMEM)|g' \
- -e 's|@''GNULIB_MEMPCPY''@|$(GNULIB_MEMPCPY)|g' \
- -e 's|@''GNULIB_MEMRCHR''@|$(GNULIB_MEMRCHR)|g' \
- -e 's|@''GNULIB_STPCPY''@|$(GNULIB_STPCPY)|g' \
- -e 's|@''GNULIB_STPNCPY''@|$(GNULIB_STPNCPY)|g' \
- -e 's|@''GNULIB_STRCHRNUL''@|$(GNULIB_STRCHRNUL)|g' \
- -e 's|@''GNULIB_STRDUP''@|$(GNULIB_STRDUP)|g' \
- -e 's|@''GNULIB_STRNDUP''@|$(GNULIB_STRNDUP)|g' \
- -e 's|@''GNULIB_STRNLEN''@|$(GNULIB_STRNLEN)|g' \
- -e 's|@''GNULIB_STRPBRK''@|$(GNULIB_STRPBRK)|g' \
- -e 's|@''GNULIB_STRSEP''@|$(GNULIB_STRSEP)|g' \
- -e 's|@''GNULIB_STRCASESTR''@|$(GNULIB_STRCASESTR)|g' \
- -e 's|@''GNULIB_STRTOK_R''@|$(GNULIB_STRTOK_R)|g' \
- -e 's|@''HAVE_DECL_MEMMEM''@|$(HAVE_DECL_MEMMEM)|g' \
- -e 's|@''HAVE_MEMPCPY''@|$(HAVE_MEMPCPY)|g' \
- -e 's|@''HAVE_DECL_MEMRCHR''@|$(HAVE_DECL_MEMRCHR)|g' \
- -e 's|@''HAVE_STPCPY''@|$(HAVE_STPCPY)|g' \
- -e 's|@''HAVE_STPNCPY''@|$(HAVE_STPNCPY)|g' \
- -e 's|@''HAVE_STRCASECMP''@|$(HAVE_STRCASECMP)|g' \
- -e 's|@''HAVE_DECL_STRNCASECMP''@|$(HAVE_DECL_STRNCASECMP)|g' \
- -e 's|@''HAVE_STRCHRNUL''@|$(HAVE_STRCHRNUL)|g' \
- -e 's|@''HAVE_DECL_STRDUP''@|$(HAVE_DECL_STRDUP)|g' \
- -e 's|@''HAVE_STRNDUP''@|$(HAVE_STRNDUP)|g' \
- -e 's|@''HAVE_DECL_STRNDUP''@|$(HAVE_DECL_STRNDUP)|g' \
- -e 's|@''HAVE_DECL_STRNLEN''@|$(HAVE_DECL_STRNLEN)|g' \
- -e 's|@''HAVE_STRPBRK''@|$(HAVE_STRPBRK)|g' \
- -e 's|@''HAVE_STRSEP''@|$(HAVE_STRSEP)|g' \
- -e 's|@''HAVE_STRCASESTR''@|$(HAVE_STRCASESTR)|g' \
- -e 's|@''HAVE_DECL_STRTOK_R''@|$(HAVE_DECL_STRTOK_R)|g' \
- -e '/definition of GL_LINK_WARNING/r $(LINK_WARNING_H)' \
- < $(srcdir)/string_.h; \
- } > $@-t
- mv $@-t $@
-MOSTLYCLEANFILES += string.h string.h-t
-
-EXTRA_DIST += string_.h
-
-## end gnulib module string
-
-## begin gnulib module sys_socket
-
-BUILT_SOURCES += $(SYS_SOCKET_H)
-
-# We need the following in order to create <sys/socket.h> when the system
-# doesn't have one that works with the given compiler.
-sys/socket.h: sys_socket_.h
- @MKDIR_P@ sys
- { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
- sed -e 's/@''INCLUDE_NEXT''@/$(INCLUDE_NEXT)/g' \
- -e 's|@''NEXT_SYS_SOCKET_H''@|$(NEXT_SYS_SOCKET_H)|g' \
- -e 's|@''HAVE_SYS_SOCKET_H''@|$(HAVE_SYS_SOCKET_H)|g' \
- -e 's|@''HAVE_WINSOCK2_H''@|$(HAVE_WINSOCK2_H)|g' \
- -e 's|@''HAVE_WS2TCPIP_H''@|$(HAVE_WS2TCPIP_H)|g' \
- < $(srcdir)/sys_socket_.h; \
- } > $@-t
- mv -f $@-t $@
-MOSTLYCLEANFILES += sys/socket.h sys/socket.h-t
-MOSTLYCLEANDIRS += sys
-
-EXTRA_DIST += sys_socket_.h
-
-## end gnulib module sys_socket
-
-## begin gnulib module unistd
-
-BUILT_SOURCES += unistd.h
-
-# We need the following in order to create an empty placeholder for
-# <unistd.h> when the system doesn't have one.
-unistd.h: unistd_.h
- rm -f $@-t $@
- { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
- sed -e 's|@''HAVE_UNISTD_H''@|$(HAVE_UNISTD_H)|g' \
- -e 's/@''INCLUDE_NEXT''@/$(INCLUDE_NEXT)/g' \
- -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_FCHDIR''@|$(GNULIB_FCHDIR)|g' \
- -e 's|@''GNULIB_FTRUNCATE''@|$(GNULIB_FTRUNCATE)|g' \
- -e 's|@''GNULIB_GETCWD''@|$(GNULIB_GETCWD)|g' \
- -e 's|@''GNULIB_GETLOGIN_R''@|$(GNULIB_GETLOGIN_R)|g' \
- -e 's|@''GNULIB_LCHOWN''@|$(GNULIB_LCHOWN)|g' \
- -e 's|@''GNULIB_LSEEK''@|$(GNULIB_LSEEK)|g' \
- -e 's|@''GNULIB_READLINK''@|$(GNULIB_READLINK)|g' \
- -e 's|@''GNULIB_SLEEP''@|$(GNULIB_SLEEP)|g' \
- -e 's|@''HAVE_DUP2''@|$(HAVE_DUP2)|g' \
- -e 's|@''HAVE_FTRUNCATE''@|$(HAVE_FTRUNCATE)|g' \
- -e 's|@''HAVE_READLINK''@|$(HAVE_READLINK)|g' \
- -e 's|@''HAVE_SLEEP''@|$(HAVE_SLEEP)|g' \
- -e 's|@''HAVE_DECL_GETLOGIN_R''@|$(HAVE_DECL_GETLOGIN_R)|g' \
- -e 's|@''REPLACE_CHOWN''@|$(REPLACE_CHOWN)|g' \
- -e 's|@''REPLACE_FCHDIR''@|$(REPLACE_FCHDIR)|g' \
- -e 's|@''REPLACE_GETCWD''@|$(REPLACE_GETCWD)|g' \
- -e 's|@''REPLACE_LCHOWN''@|$(REPLACE_LCHOWN)|g' \
- -e 's|@''REPLACE_LSEEK''@|$(REPLACE_LSEEK)|g' \
- < $(srcdir)/unistd_.h; \
- } > $@-t
- mv $@-t $@
-MOSTLYCLEANFILES += unistd.h unistd.h-t
-
-EXTRA_DIST += unistd_.h
-
-## end gnulib module unistd
-
## begin gnulib module version-etc
libgnu_la_SOURCES += version-etc.h version-etc.c
diff --git a/gl/m4/extensions.m4 b/gl/m4/extensions.m4
deleted file mode 100644
index 143a9e5403..0000000000
--- a/gl/m4/extensions.m4
+++ /dev/null
@@ -1,58 +0,0 @@
-# serial 4 -*- Autoconf -*-
-# Enable extensions on systems that normally disable them.
-
-# Copyright (C) 2003, 2006 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
-# Autoconf. Perhaps we can remove this once we can assume Autoconf
-# 2.61 or later everywhere, but since CVS Autoconf mutates rapidly
-# enough in this area it's likely we'll need to redefine
-# AC_USE_SYSTEM_EXTENSIONS for quite some time.
-
-# AC_USE_SYSTEM_EXTENSIONS
-# ------------------------
-# Enable extensions on systems that normally disable them,
-# typically due to standards-conformance issues.
-AC_DEFUN([AC_USE_SYSTEM_EXTENSIONS],
-[
- AC_BEFORE([$0], [AC_COMPILE_IFELSE])
- AC_BEFORE([$0], [AC_RUN_IFELSE])
-
- AC_REQUIRE([AC_GNU_SOURCE])
- AC_REQUIRE([AC_AIX])
- AC_REQUIRE([AC_MINIX])
-
- AH_VERBATIM([__EXTENSIONS__],
-[/* Enable extensions on Solaris. */
-#ifndef __EXTENSIONS__
-# undef __EXTENSIONS__
-#endif
-#ifndef _POSIX_PTHREAD_SEMANTICS
-# undef _POSIX_PTHREAD_SEMANTICS
-#endif
-#ifndef _TANDEM_SOURCE
-# undef _TANDEM_SOURCE
-#endif])
- AC_CACHE_CHECK([whether it is safe to define __EXTENSIONS__],
- [ac_cv_safe_to_define___extensions__],
- [AC_COMPILE_IFELSE(
- [AC_LANG_PROGRAM([
-# define __EXTENSIONS__ 1
- AC_INCLUDES_DEFAULT])],
- [ac_cv_safe_to_define___extensions__=yes],
- [ac_cv_safe_to_define___extensions__=no])])
- test $ac_cv_safe_to_define___extensions__ = yes &&
- AC_DEFINE([__EXTENSIONS__])
- AC_DEFINE([_POSIX_PTHREAD_SEMANTICS])
- AC_DEFINE([_TANDEM_SOURCE])
-])
-
-# gl_USE_SYSTEM_EXTENSIONS
-# ------------------------
-# Enable extensions on systems that normally disable them,
-# typically due to standards-conformance issues.
-AC_DEFUN([gl_USE_SYSTEM_EXTENSIONS],
- [AC_REQUIRE([AC_USE_SYSTEM_EXTENSIONS])])
diff --git a/gl/m4/gnulib-cache.m4 b/gl/m4/gnulib-cache.m4
index 00da5468c4..4ca757a20d 100644
--- a/gl/m4/gnulib-cache.m4
+++ b/gl/m4/gnulib-cache.m4
@@ -15,12 +15,12 @@
# Specification in the form of a command-line invocation:
-# gnulib-tool --import --dir=. --local-dir=gl/override --lib=libgnu --source-base=gl --m4-base=gl/m4 --doc-base=doc --aux-dir=build-aux --avoid=snprintf --avoid=vasnprintf --makefile-name=gnulib.mk --libtool --macro-prefix=gl arpa_inet error fdl gendocs getaddrinfo getline getpass gpl-2.0 inet_ntop inet_pton lgpl-2.1 maintainer-makefile progname readline version-etc-fsf
+# gnulib-tool --import --dir=. --local-dir=gl/override --lib=libgnu --source-base=gl --m4-base=gl/m4 --doc-base=doc --aux-dir=build-aux --avoid=gettext-h --avoid=malloc-posix --avoid=realloc-posix --avoid=snprintf --avoid=stdbool --avoid=stdio --avoid=string --avoid=sys_socket --avoid=unistd --avoid=vasnprintf --makefile-name=gnulib.mk --libtool --macro-prefix=gl arpa_inet error fdl gendocs getaddrinfo getline getpass gpl-2.0 inet_ntop inet_pton lgpl-2.1 maintainer-makefile progname readline version-etc-fsf
# Specification in the form of a few gnulib-tool.m4 macro invocations:
gl_LOCAL_DIR([gl/override])
gl_MODULES([arpa_inet error fdl gendocs getaddrinfo getline getpass gpl-2.0 inet_ntop inet_pton lgpl-2.1 maintainer-makefile progname readline version-etc-fsf])
-gl_AVOID([snprintf vasnprintf])
+gl_AVOID([gettext-h malloc-posix realloc-posix snprintf stdbool stdio string sys_socket unistd vasnprintf])
gl_SOURCE_BASE([gl])
gl_M4_BASE([gl/m4])
gl_PO_BASE([])
diff --git a/gl/m4/gnulib-comp.m4 b/gl/m4/gnulib-comp.m4
index bbe54c1758..fcade33317 100644
--- a/gl/m4/gnulib-comp.m4
+++ b/gl/m4/gnulib-comp.m4
@@ -26,7 +26,6 @@ AC_DEFUN([gl_EARLY],
m4_pattern_allow([^gl_LTLIBOBJS$])dnl a variable
AC_REQUIRE([AC_PROG_RANLIB])
AC_REQUIRE([AC_GNU_SOURCE])
- AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS])
AC_REQUIRE([AC_FUNC_FSEEKO])
dnl Some compilers (e.g., AIX 5.3 cc) need to be in c99 mode
dnl for the builtin va_copy to work. With Autoconf 2.60 or later,
@@ -56,8 +55,6 @@ AC_DEFUN([gl_INIT],
gl_FUNC_GETLINE
gl_STDIO_MODULE_INDICATOR([getline])
gl_FUNC_GETPASS
- AC_SUBST([LIBINTL])
- AC_SUBST([LTLIBINTL])
gl_INET_NTOP
gl_INET_PTON
gl_FUNC_LSEEK
@@ -67,14 +64,8 @@ AC_DEFUN([gl_INIT],
gl_FUNC_READLINE
gl_TYPE_SOCKLEN_T
gl_STDARG_H
- AM_STDBOOL_H
- gl_STDIO_H
gl_FUNC_STRDUP
gl_STRING_MODULE_INDICATOR([strdup])
- gl_HEADER_STRING_H
- gl_HEADER_SYS_SOCKET
- AC_PROG_MKDIR_P
- gl_UNISTD_H
m4_popdef([AC_LIBSOURCES])
m4_popdef([AC_REPLACE_FUNCS])
m4_popdef([AC_LIBOBJ])
@@ -115,7 +106,6 @@ AC_DEFUN([gl_FILE_LIST], [
build-aux/GNUmakefile
build-aux/config.rpath
build-aux/gendocs.sh
- build-aux/link-warning.h
build-aux/maint.mk
doc/fdl.texi
doc/gendocs_template
@@ -131,7 +121,6 @@ AC_DEFUN([gl_FILE_LIST], [
lib/getline.c
lib/getpass.c
lib/getpass.h
- lib/gettext.h
lib/inet_ntop.c
lib/inet_ntop.h
lib/inet_pton.c
@@ -142,18 +131,12 @@ AC_DEFUN([gl_FILE_LIST], [
lib/progname.h
lib/readline.c
lib/readline.h
- lib/stdbool_.h
- lib/stdio_.h
lib/strdup.c
- lib/string_.h
- lib/sys_socket_.h
- lib/unistd_.h
lib/version-etc-fsf.c
lib/version-etc.c
lib/version-etc.h
m4/arpa_inet_h.m4
m4/error.m4
- m4/extensions.m4
m4/fseeko.m4
m4/getaddrinfo.m4
m4/getdelim.m4
@@ -170,12 +153,6 @@ AC_DEFUN([gl_FILE_LIST], [
m4/netinet_in_h.m4
m4/readline.m4
m4/socklen.m4
- m4/sockpfaf.m4
m4/stdarg.m4
- m4/stdbool.m4
- m4/stdio_h.m4
m4/strdup.m4
- m4/string_h.m4
- m4/sys_socket_h.m4
- m4/unistd_h.m4
])
diff --git a/gl/m4/sockpfaf.m4 b/gl/m4/sockpfaf.m4
deleted file mode 100644
index 25d9755c5e..0000000000
--- a/gl/m4/sockpfaf.m4
+++ /dev/null
@@ -1,58 +0,0 @@
-# sockpfaf.m4 serial 5
-dnl Copyright (C) 2004, 2006 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 Test for some common socket protocol families (PF_INET, PF_INET6, ...)
-dnl and some common address families (AF_INET, AF_INET6, ...).
-dnl This test assumes that a system supports an address family if and only if
-dnl it supports the corresponding protocol family.
-
-dnl From Bruno Haible.
-
-AC_DEFUN([gl_SOCKET_FAMILIES],
-[
- AC_REQUIRE([gl_HEADER_SYS_SOCKET])
- AC_CHECK_HEADERS_ONCE([netinet/in.h])
-
- AC_MSG_CHECKING(for IPv4 sockets)
- AC_CACHE_VAL(gl_cv_socket_ipv4,
- [AC_TRY_COMPILE([#include <sys/types.h>
-#ifdef HAVE_SYS_SOCKET_H
-#include <sys/socket.h>
-#endif
-#ifdef HAVE_NETINET_IN_H
-#include <netinet/in.h>
-#endif
-#ifdef HAVE_WINSOCK2_H
-#include <winsock2.h>
-#endif],
-[int x = AF_INET; struct in_addr y; struct sockaddr_in z;
- if (&x && &y && &z) return 0;],
- gl_cv_socket_ipv4=yes, gl_cv_socket_ipv4=no)])
- AC_MSG_RESULT($gl_cv_socket_ipv4)
- if test $gl_cv_socket_ipv4 = yes; then
- AC_DEFINE(HAVE_IPV4, 1, [Define to 1 if <sys/socket.h> defines AF_INET.])
- fi
-
- AC_MSG_CHECKING(for IPv6 sockets)
- AC_CACHE_VAL(gl_cv_socket_ipv6,
- [AC_TRY_COMPILE([#include <sys/types.h>
-#ifdef HAVE_SYS_SOCKET_H
-#include <sys/socket.h>
-#endif
-#ifdef HAVE_NETINET_IN_H
-#include <netinet/in.h>
-#endif
-#ifdef HAVE_WINSOCK2_H
-#include <winsock2.h>
-#endif],
-[int x = AF_INET6; struct in6_addr y; struct sockaddr_in6 z;
- if (&x && &y && &z) return 0;],
- gl_cv_socket_ipv6=yes, gl_cv_socket_ipv6=no)])
- AC_MSG_RESULT($gl_cv_socket_ipv6)
- if test $gl_cv_socket_ipv6 = yes; then
- AC_DEFINE(HAVE_IPV6, 1, [Define to 1 if <sys/socket.h> defines AF_INET6.])
- fi
-])
diff --git a/gl/m4/stdbool.m4 b/gl/m4/stdbool.m4
deleted file mode 100644
index 2204ecd984..0000000000
--- a/gl/m4/stdbool.m4
+++ /dev/null
@@ -1,115 +0,0 @@
-# Check for stdbool.h that conforms to C99.
-
-dnl Copyright (C) 2002-2006 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.
-
-# Prepare for substituting <stdbool.h> if it is not supported.
-
-AC_DEFUN([AM_STDBOOL_H],
-[
- AC_REQUIRE([AC_HEADER_STDBOOL])
-
- # Define two additional variables used in the Makefile substitution.
-
- if test "$ac_cv_header_stdbool_h" = yes; then
- STDBOOL_H=''
- else
- STDBOOL_H='stdbool.h'
- fi
- AC_SUBST([STDBOOL_H])
-
- if test "$ac_cv_type__Bool" = yes; then
- HAVE__BOOL=1
- else
- HAVE__BOOL=0
- fi
- AC_SUBST([HAVE__BOOL])
-])
-
-# AM_STDBOOL_H will be renamed to gl_STDBOOL_H in the future.
-AC_DEFUN([gl_STDBOOL_H], [AM_STDBOOL_H])
-
-# This macro is only needed in autoconf <= 2.59. Newer versions of autoconf
-# have this macro built-in.
-
-AC_DEFUN([AC_HEADER_STDBOOL],
- [AC_CACHE_CHECK([for stdbool.h that conforms to C99],
- [ac_cv_header_stdbool_h],
- [AC_TRY_COMPILE(
- [
- #include <stdbool.h>
- #ifndef bool
- "error: bool is not defined"
- #endif
- #ifndef false
- "error: false is not defined"
- #endif
- #if false
- "error: false is not 0"
- #endif
- #ifndef true
- "error: true is not defined"
- #endif
- #if true != 1
- "error: true is not 1"
- #endif
- #ifndef __bool_true_false_are_defined
- "error: __bool_true_false_are_defined is not defined"
- #endif
-
- struct s { _Bool s: 1; _Bool t; } s;
-
- char a[true == 1 ? 1 : -1];
- char b[false == 0 ? 1 : -1];
- char c[__bool_true_false_are_defined == 1 ? 1 : -1];
- char d[(bool) 0.5 == true ? 1 : -1];
- bool e = &s;
- char f[(_Bool) 0.0 == false ? 1 : -1];
- char g[true];
- char h[sizeof (_Bool)];
- char i[sizeof s.t];
- enum { j = false, k = true, l = false * true, m = true * 256 };
- _Bool n[m];
- char o[sizeof n == m * sizeof n[0] ? 1 : -1];
- char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
- #if defined __xlc__ || defined __GNUC__
- /* Catch a bug in IBM AIX xlc compiler version 6.0.0.0
- reported by James Lemley on 2005-10-05; see
- http://lists.gnu.org/archive/html/bug-coreutils/2005-10/msg00086.html
- This test is not quite right, since xlc is allowed to
- reject this program, as the initializer for xlcbug is
- not one of the forms that C requires support for.
- However, doing the test right would require a run-time
- test, and that would make cross-compilation harder.
- Let us hope that IBM fixes the xlc bug, and also adds
- support for this kind of constant expression. In the
- meantime, this test will reject xlc, which is OK, since
- our stdbool.h substitute should suffice. We also test
- this with GCC, where it should work, to detect more
- quickly whether someone messes up the test in the
- future. */
- char digs[] = "0123456789";
- int xlcbug = 1 / (&(digs + 5)[-2 + (bool) 1] == &digs[4] ? 1 : -1);
- #endif
- /* Catch a bug in an HP-UX C compiler. See
- http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
- http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
- */
- _Bool q = true;
- _Bool *pq = &q;
- ],
- [
- *pq |= q;
- *pq |= ! q;
- /* Refer to every declared value, to avoid compiler optimizations. */
- return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
- + !m + !n + !o + !p + !q + !pq);
- ],
- [ac_cv_header_stdbool_h=yes],
- [ac_cv_header_stdbool_h=no])])
- AC_CHECK_TYPES([_Bool])
- if test $ac_cv_header_stdbool_h = yes; then
- AC_DEFINE(HAVE_STDBOOL_H, 1, [Define to 1 if stdbool.h conforms to C99.])
- fi])
diff --git a/gl/m4/stdio_h.m4 b/gl/m4/stdio_h.m4
deleted file mode 100644
index b9a69984f6..0000000000
--- a/gl/m4/stdio_h.m4
+++ /dev/null
@@ -1,82 +0,0 @@
-# stdio_h.m4 serial 7
-dnl Copyright (C) 2007 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],
-[
- AC_REQUIRE([gl_STDIO_H_DEFAULTS])
- gl_CHECK_NEXT_HEADERS([stdio.h])
-])
-
-AC_DEFUN([gl_STDIO_MODULE_INDICATOR],
-[
- dnl Use AC_REQUIRE here, so that the default settings are expanded once only.
- AC_REQUIRE([gl_STDIO_H_DEFAULTS])
- GNULIB_[]m4_translit([$1],[abcdefghijklmnopqrstuvwxyz./-],[ABCDEFGHIJKLMNOPQRSTUVWXYZ___])=1
-])
-
-AC_DEFUN([gl_STDIO_H_DEFAULTS],
-[
- GNULIB_FPRINTF_POSIX=0; AC_SUBST([GNULIB_FPRINTF_POSIX])
- GNULIB_PRINTF_POSIX=0; AC_SUBST([GNULIB_PRINTF_POSIX])
- GNULIB_SNPRINTF=0; AC_SUBST([GNULIB_SNPRINTF])
- GNULIB_SPRINTF_POSIX=0; AC_SUBST([GNULIB_SPRINTF_POSIX])
- GNULIB_VFPRINTF_POSIX=0; AC_SUBST([GNULIB_VFPRINTF_POSIX])
- GNULIB_VPRINTF_POSIX=0; AC_SUBST([GNULIB_VPRINTF_POSIX])
- GNULIB_VSNPRINTF=0; AC_SUBST([GNULIB_VSNPRINTF])
- GNULIB_VSPRINTF_POSIX=0; AC_SUBST([GNULIB_VSPRINTF_POSIX])
- GNULIB_VASPRINTF=0; AC_SUBST([GNULIB_VASPRINTF])
- GNULIB_FSEEK=0; AC_SUBST([GNULIB_FSEEK])
- GNULIB_FSEEKO=0; AC_SUBST([GNULIB_FSEEKO])
- GNULIB_FTELL=0; AC_SUBST([GNULIB_FTELL])
- GNULIB_FTELLO=0; AC_SUBST([GNULIB_FTELLO])
- GNULIB_FFLUSH=0; AC_SUBST([GNULIB_FFLUSH])
- GNULIB_GETDELIM=0; AC_SUBST([GNULIB_GETDELIM])
- GNULIB_GETLINE=0; AC_SUBST([GNULIB_GETLINE])
- dnl Assume proper GNU behavior unless another module says otherwise.
- REPLACE_FPRINTF=0; AC_SUBST([REPLACE_FPRINTF])
- REPLACE_VFPRINTF=0; AC_SUBST([REPLACE_VFPRINTF])
- REPLACE_PRINTF=0; AC_SUBST([REPLACE_PRINTF])
- REPLACE_VPRINTF=0; AC_SUBST([REPLACE_VPRINTF])
- REPLACE_SNPRINTF=0; AC_SUBST([REPLACE_SNPRINTF])
- HAVE_DECL_SNPRINTF=1; AC_SUBST([HAVE_DECL_SNPRINTF])
- REPLACE_VSNPRINTF=0; AC_SUBST([REPLACE_VSNPRINTF])
- HAVE_DECL_VSNPRINTF=1; AC_SUBST([HAVE_DECL_VSNPRINTF])
- REPLACE_SPRINTF=0; AC_SUBST([REPLACE_SPRINTF])
- REPLACE_VSPRINTF=0; AC_SUBST([REPLACE_VSPRINTF])
- HAVE_VASPRINTF=1; AC_SUBST([HAVE_VASPRINTF])
- REPLACE_VASPRINTF=0; AC_SUBST([REPLACE_VASPRINTF])
- HAVE_FSEEKO=1; AC_SUBST([HAVE_FSEEKO])
- REPLACE_FSEEKO=0; AC_SUBST([REPLACE_FSEEKO])
- REPLACE_FSEEK=0; AC_SUBST([REPLACE_FSEEK])
- HAVE_FTELLO=1; AC_SUBST([HAVE_FTELLO])
- REPLACE_FTELLO=0; AC_SUBST([REPLACE_FTELLO])
- REPLACE_FTELL=0; AC_SUBST([REPLACE_FTELL])
- REPLACE_FFLUSH=0; AC_SUBST([REPLACE_FFLUSH])
- HAVE_DECL_GETDELIM=1; AC_SUBST([HAVE_DECL_GETDELIM])
- HAVE_DECL_GETLINE=1; AC_SUBST([HAVE_DECL_GETLINE])
- REPLACE_GETLINE=0; AC_SUBST([REPLACE_GETLINE])
-])
-
-dnl Code shared by fseeko and ftello. Determine if large files are supported,
-dnl but stdin does not start as a large file by default.
-AC_DEFUN([gl_STDIN_LARGE_OFFSET],
- [
- AC_CACHE_CHECK([whether stdin defaults to large file offsets],
- [gl_cv_var_stdin_large_offset],
- [AC_LINK_IFELSE([AC_LANG_PROGRAM([#include <stdio.h>],
-[#if defined __SL64 && defined __SCLE /* cygwin */
- /* Cygwin 1.5.24 and earlier fail to put stdin in 64-bit mode, making
- fseeko/ftello needlessly fail. This bug was fixed at the same time
- that cygwin started exporting asnprintf (cygwin 1.7.0), so we use
- that as a link-time test for cross-compiles rather than building
- a runtime test. */
- size_t s;
- if (asnprintf (NULL, &s, ""))
- return 0;
-#endif])],
- [gl_cv_var_stdin_large_offset=yes],
- [gl_cv_var_stdin_large_offset=no])])
-])
diff --git a/gl/m4/string_h.m4 b/gl/m4/string_h.m4
deleted file mode 100644
index ec51e9a018..0000000000
--- a/gl/m4/string_h.m4
+++ /dev/null
@@ -1,77 +0,0 @@
-# Configure a GNU-like replacement for <string.h>.
-
-# Copyright (C) 2007 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.
-
-AC_DEFUN([gl_HEADER_STRING_H],
-[
- dnl Use AC_REQUIRE here, so that the default behavior below is expanded
- dnl once only, before all statements that occur in other macros.
- AC_REQUIRE([gl_HEADER_STRING_H_BODY])
-])
-
-AC_DEFUN([gl_HEADER_STRING_H_BODY],
-[
- AC_REQUIRE([AC_C_RESTRICT])
- AC_REQUIRE([gl_HEADER_STRING_H_DEFAULTS])
- gl_CHECK_NEXT_HEADERS([string.h])
-])
-
-AC_DEFUN([gl_STRING_MODULE_INDICATOR],
-[
- dnl Use AC_REQUIRE here, so that the default settings are expanded once only.
- AC_REQUIRE([gl_HEADER_STRING_H_DEFAULTS])
- GNULIB_[]m4_translit([$1],[abcdefghijklmnopqrstuvwxyz./-],[ABCDEFGHIJKLMNOPQRSTUVWXYZ___])=1
-])
-
-AC_DEFUN([gl_HEADER_STRING_H_DEFAULTS],
-[
- GNULIB_MEMMEM=0; AC_SUBST([GNULIB_MEMMEM])
- GNULIB_MEMPCPY=0; AC_SUBST([GNULIB_MEMPCPY])
- GNULIB_MEMRCHR=0; AC_SUBST([GNULIB_MEMRCHR])
- GNULIB_STPCPY=0; AC_SUBST([GNULIB_STPCPY])
- GNULIB_STPNCPY=0; AC_SUBST([GNULIB_STPNCPY])
- GNULIB_STRCHRNUL=0; AC_SUBST([GNULIB_STRCHRNUL])
- GNULIB_STRDUP=0; AC_SUBST([GNULIB_STRDUP])
- GNULIB_STRNDUP=0; AC_SUBST([GNULIB_STRNDUP])
- GNULIB_STRNLEN=0; AC_SUBST([GNULIB_STRNLEN])
- GNULIB_STRPBRK=0; AC_SUBST([GNULIB_STRPBRK])
- GNULIB_STRSEP=0; AC_SUBST([GNULIB_STRSEP])
- GNULIB_STRCASESTR=0; AC_SUBST([GNULIB_STRCASESTR])
- GNULIB_STRTOK_R=0; AC_SUBST([GNULIB_STRTOK_R])
- GNULIB_MBSLEN=0; AC_SUBST([GNULIB_MBSLEN])
- GNULIB_MBSNLEN=0; AC_SUBST([GNULIB_MBSNLEN])
- GNULIB_MBSCHR=0; AC_SUBST([GNULIB_MBSCHR])
- GNULIB_MBSRCHR=0; AC_SUBST([GNULIB_MBSRCHR])
- GNULIB_MBSSTR=0; AC_SUBST([GNULIB_MBSSTR])
- GNULIB_MBSCASECMP=0; AC_SUBST([GNULIB_MBSCASECMP])
- GNULIB_MBSNCASECMP=0; AC_SUBST([GNULIB_MBSNCASECMP])
- GNULIB_MBSPCASECMP=0; AC_SUBST([GNULIB_MBSPCASECMP])
- GNULIB_MBSCASESTR=0; AC_SUBST([GNULIB_MBSCASESTR])
- GNULIB_MBSCSPN=0; AC_SUBST([GNULIB_MBSCSPN])
- GNULIB_MBSPBRK=0; AC_SUBST([GNULIB_MBSPBRK])
- GNULIB_MBSSPN=0; AC_SUBST([GNULIB_MBSSPN])
- GNULIB_MBSSEP=0; AC_SUBST([GNULIB_MBSSEP])
- GNULIB_MBSTOK_R=0; AC_SUBST([GNULIB_MBSTOK_R])
- dnl Assume proper GNU behavior unless another module says otherwise.
- HAVE_DECL_MEMMEM=1; AC_SUBST([HAVE_DECL_MEMMEM])
- HAVE_MEMPCPY=1; AC_SUBST([HAVE_MEMPCPY])
- HAVE_DECL_MEMRCHR=1; AC_SUBST([HAVE_DECL_MEMRCHR])
- HAVE_STPCPY=1; AC_SUBST([HAVE_STPCPY])
- HAVE_STPNCPY=1; AC_SUBST([HAVE_STPNCPY])
- HAVE_STRCASECMP=1; AC_SUBST([HAVE_STRCASECMP])
- HAVE_DECL_STRNCASECMP=1; AC_SUBST([HAVE_DECL_STRNCASECMP])
- HAVE_STRCHRNUL=1; AC_SUBST([HAVE_STRCHRNUL])
- HAVE_DECL_STRDUP=1; AC_SUBST([HAVE_DECL_STRDUP])
- HAVE_STRNDUP=1; AC_SUBST([HAVE_STRNDUP])
- HAVE_DECL_STRNDUP=1; AC_SUBST([HAVE_DECL_STRNDUP])
- HAVE_DECL_STRNLEN=1; AC_SUBST([HAVE_DECL_STRNLEN])
- HAVE_STRPBRK=1; AC_SUBST([HAVE_STRPBRK])
- HAVE_STRSEP=1; AC_SUBST([HAVE_STRSEP])
- HAVE_STRCASESTR=1; AC_SUBST([HAVE_STRCASESTR])
- HAVE_DECL_STRTOK_R=1; AC_SUBST([HAVE_DECL_STRTOK_R])
-])
diff --git a/gl/m4/sys_socket_h.m4 b/gl/m4/sys_socket_h.m4
deleted file mode 100644
index d9659c2d75..0000000000
--- a/gl/m4/sys_socket_h.m4
+++ /dev/null
@@ -1,51 +0,0 @@
-# sys_socket_h.m4 serial 4
-dnl Copyright (C) 2005, 2006, 2007 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_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
- SYS_SOCKET_H=''
- else
- SYS_SOCKET_H='sys/socket.h'
-
- gl_CHECK_NEXT_HEADERS([sys/socket.h])
- if test $ac_cv_header_sys_socket_h = yes; then
- HAVE_SYS_SOCKET_H=1
- HAVE_WINSOCK2_H=0
- HAVE_WS2TCPIP_H=0
- else
- HAVE_SYS_SOCKET_H=0
- 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 ws2tcpip.h])
- if test $ac_cv_header_winsock2_h = yes; then
- HAVE_WINSOCK2_H=1
- else
- HAVE_WINSOCK2_H=0
- fi
- 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_WINSOCK2_H])
- AC_SUBST([HAVE_WS2TCPIP_H])
- fi
- AC_SUBST([SYS_SOCKET_H])
-])
diff --git a/gl/m4/unistd_h.m4 b/gl/m4/unistd_h.m4
deleted file mode 100644
index b12f84e8ec..0000000000
--- a/gl/m4/unistd_h.m4
+++ /dev/null
@@ -1,56 +0,0 @@
-# unistd_h.m4 serial 9
-dnl Copyright (C) 2006-2007 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 Written by Simon Josefsson, Bruno Haible.
-
-AC_DEFUN([gl_UNISTD_H],
-[
- dnl Use AC_REQUIRE here, so that the default behavior below is expanded
- dnl once only, before all statements that occur in other macros.
- AC_REQUIRE([gl_UNISTD_H_DEFAULTS])
-
- gl_CHECK_NEXT_HEADERS([unistd.h])
-
- AC_CHECK_HEADERS_ONCE([unistd.h])
- if test $ac_cv_header_unistd_h = yes; then
- HAVE_UNISTD_H=1
- else
- HAVE_UNISTD_H=0
- fi
- AC_SUBST([HAVE_UNISTD_H])
-])
-
-AC_DEFUN([gl_UNISTD_MODULE_INDICATOR],
-[
- dnl Use AC_REQUIRE here, so that the default settings are expanded once only.
- AC_REQUIRE([gl_UNISTD_H_DEFAULTS])
- GNULIB_[]m4_translit([$1],[abcdefghijklmnopqrstuvwxyz./-],[ABCDEFGHIJKLMNOPQRSTUVWXYZ___])=1
-])
-
-AC_DEFUN([gl_UNISTD_H_DEFAULTS],
-[
- GNULIB_CHOWN=0; AC_SUBST([GNULIB_CHOWN])
- GNULIB_DUP2=0; AC_SUBST([GNULIB_DUP2])
- GNULIB_FCHDIR=0; AC_SUBST([GNULIB_FCHDIR])
- GNULIB_FTRUNCATE=0; AC_SUBST([GNULIB_FTRUNCATE])
- GNULIB_GETCWD=0; AC_SUBST([GNULIB_GETCWD])
- GNULIB_GETLOGIN_R=0; AC_SUBST([GNULIB_GETLOGIN_R])
- GNULIB_LCHOWN=0; AC_SUBST([GNULIB_LCHOWN])
- GNULIB_LSEEK=0; AC_SUBST([GNULIB_LSEEK])
- GNULIB_READLINK=0; AC_SUBST([GNULIB_READLINK])
- GNULIB_SLEEP=0; AC_SUBST([GNULIB_SLEEP])
- dnl Assume proper GNU behavior unless another module says otherwise.
- HAVE_DUP2=1; AC_SUBST([HAVE_DUP2])
- HAVE_FTRUNCATE=1; AC_SUBST([HAVE_FTRUNCATE])
- HAVE_READLINK=1; AC_SUBST([HAVE_READLINK])
- HAVE_SLEEP=1; AC_SUBST([HAVE_SLEEP])
- HAVE_DECL_GETLOGIN_R=1; AC_SUBST([HAVE_DECL_GETLOGIN_R])
- REPLACE_CHOWN=0; AC_SUBST([REPLACE_CHOWN])
- REPLACE_FCHDIR=0; AC_SUBST([REPLACE_FCHDIR])
- REPLACE_GETCWD=0; AC_SUBST([REPLACE_GETCWD])
- REPLACE_LCHOWN=0; AC_SUBST([REPLACE_LCHOWN])
- REPLACE_LSEEK=0; AC_SUBST([REPLACE_LSEEK])
-])
diff --git a/gl/stdbool_.h b/gl/stdbool_.h
deleted file mode 100644
index 150a0102e1..0000000000
--- a/gl/stdbool_.h
+++ /dev/null
@@ -1,118 +0,0 @@
-/* Copyright (C) 2001, 2002, 2003, 2006, 2007 Free Software Foundation, Inc.
- Written by Bruno Haible <haible@clisp.cons.org>, 2001.
-
- 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 2, 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_STDBOOL_H
-#define _GL_STDBOOL_H
-
-/* ISO C 99 <stdbool.h> for platforms that lack it. */
-
-/* Usage suggestions:
-
- Programs that use <stdbool.h> should be aware of some limitations
- and standards compliance issues.
-
- Standards compliance:
-
- - <stdbool.h> must be #included before 'bool', 'false', 'true'
- can be used.
-
- - You cannot assume that sizeof (bool) == 1.
-
- - Programs should not undefine the macros bool, true, and false,
- as C99 lists that as an "obsolescent feature".
-
- Limitations of this substitute, when used in a C89 environment:
-
- - <stdbool.h> must be #included before the '_Bool' type can be used.
-
- - You cannot assume that _Bool is a typedef; it might be a macro.
-
- - Bit-fields of type 'bool' are not supported. Portable code
- should use 'unsigned int foo : 1;' rather than 'bool foo : 1;'.
-
- - In C99, casts and automatic conversions to '_Bool' or 'bool' are
- performed in such a way that every nonzero value gets converted
- to 'true', and zero gets converted to 'false'. This doesn't work
- with this substitute. With this substitute, only the values 0 and 1
- give the expected result when converted to _Bool' or 'bool'.
-
- Also, it is suggested that programs use 'bool' rather than '_Bool';
- this isn't required, but 'bool' is more common. */
-
-
-/* 7.16. Boolean type and values */
-
-/* BeOS <sys/socket.h> already #defines false 0, true 1. We use the same
- definitions below, but temporarily we have to #undef them. */
-#ifdef __BEOS__
-# include <OS.h> /* defines bool but not _Bool */
-# undef false
-# undef true
-#endif
-
-/* For the sake of symbolic names in gdb, we define true and false as
- enum constants, not only as macros.
- It is tempting to write
- typedef enum { false = 0, true = 1 } _Bool;
- so that gdb prints values of type 'bool' symbolically. But if we do
- this, values of type '_Bool' may promote to 'int' or 'unsigned int'
- (see ISO C 99 6.7.2.2.(4)); however, '_Bool' must promote to 'int'
- (see ISO C 99 6.3.1.1.(2)). So we add a negative value to the
- enum; this ensures that '_Bool' promotes to 'int'. */
-#if defined __cplusplus || defined __BEOS__
- /* A compiler known to have 'bool'. */
- /* If the compiler already has both 'bool' and '_Bool', we can assume they
- are the same types. */
-# if !@HAVE__BOOL@
-typedef bool _Bool;
-# endif
-#else
-# if !defined __GNUC__
- /* If @HAVE__BOOL@:
- Some HP-UX cc and AIX IBM C compiler versions have compiler bugs when
- the built-in _Bool type is used. See
- http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
- http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
- http://lists.gnu.org/archive/html/bug-coreutils/2005-10/msg00086.html
- Similar bugs are likely with other compilers as well; this file
- wouldn't be used if <stdbool.h> was working.
- So we override the _Bool type.
- If !@HAVE__BOOL@:
- Need to define _Bool ourselves. As 'signed char' or as an enum type?
- Use of a typedef, with SunPRO C, leads to a stupid
- "warning: _Bool is a keyword in ISO C99".
- Use of an enum type, with IRIX cc, leads to a stupid
- "warning(1185): enumerated type mixed with another type".
- The only benefit of the enum type, debuggability, is not important
- with these compilers. So use 'signed char' and no typedef. */
-# define _Bool signed char
-enum { false = 0, true = 1 };
-# else
- /* With this compiler, trust the _Bool type if the compiler has it. */
-# if !@HAVE__BOOL@
-typedef enum { _Bool_must_promote_to_int = -1, false = 0, true = 1 } _Bool;
-# endif
-# endif
-#endif
-#define bool _Bool
-
-/* The other macros must be usable in preprocessor directives. */
-#define false 0
-#define true 1
-#define __bool_true_false_are_defined 1
-
-#endif /* _GL_STDBOOL_H */
diff --git a/gl/stdio_.h b/gl/stdio_.h
deleted file mode 100644
index 76d9856377..0000000000
--- a/gl/stdio_.h
+++ /dev/null
@@ -1,353 +0,0 @@
-/* A GNU-like <stdio.h>.
-
- Copyright (C) 2004, 2007 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 2, 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. */
-
-#if defined __need_FILE || defined __need___FILE
-/* Special invocation convention inside glibc header files. */
-
-#@INCLUDE_NEXT@ @NEXT_STDIO_H@
-
-#else
-/* Normal invocation convention. */
-
-#ifndef _GL_STDIO_H
-
-/* The include_next requires a split double-inclusion guard. */
-#@INCLUDE_NEXT@ @NEXT_STDIO_H@
-
-#ifndef _GL_STDIO_H
-#define _GL_STDIO_H
-
-#include <stdarg.h>
-#include <stddef.h>
-
-#if (@GNULIB_FSEEKO@ && @REPLACE_FSEEKO@) \
- || (@GNULIB_FTELLO@ && @REPLACE_FTELLO@) \
- || (@GNULIB_GETDELIM@ && !@HAVE_DECL_GETDELIM@) \
- || (@GNULIB_GETLINE@ && (!@HAVE_DECL_GETLINE@ || @REPLACE_GETLINE@))
-/* Get off_t and ssize_t. */
-# include <sys/types.h>
-#endif
-
-#ifndef __attribute__
-/* This feature is available in gcc versions 2.5 and later. */
-# if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 5) || __STRICT_ANSI__
-# define __attribute__(Spec) /* empty */
-# endif
-/* The __-protected variants of `format' and `printf' attributes
- are accepted by gcc versions 2.6.4 (effectively 2.7) and later. */
-# if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 7)
-# define __format__ format
-# define __printf__ printf
-# endif
-#endif
-
-
-/* The definition of GL_LINK_WARNING is copied here. */
-
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-
-#if @GNULIB_FPRINTF_POSIX@
-# if @REPLACE_FPRINTF@
-# define fprintf rpl_fprintf
-extern int fprintf (FILE *fp, const char *format, ...)
- __attribute__ ((__format__ (__printf__, 2, 3)));
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef fprintf
-# define fprintf \
- (GL_LINK_WARNING ("fprintf is not always POSIX compliant - " \
- "use gnulib module fprintf-posix for portable " \
- "POSIX compliance"), \
- fprintf)
-#endif
-
-#if @GNULIB_VFPRINTF_POSIX@
-# if @REPLACE_VFPRINTF@
-# define vfprintf rpl_vfprintf
-extern int vfprintf (FILE *fp, const char *format, va_list args)
- __attribute__ ((__format__ (__printf__, 2, 0)));
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef vfprintf
-# define vfprintf(s,f,a) \
- (GL_LINK_WARNING ("vfprintf is not always POSIX compliant - " \
- "use gnulib module vfprintf-posix for portable " \
- "POSIX compliance"), \
- vfprintf (s, f, a))
-#endif
-
-#if @GNULIB_PRINTF_POSIX@
-# if @REPLACE_PRINTF@
-/* Don't break __attribute__((format(printf,M,N))). */
-# define printf __printf__
-extern int printf (const char *format, ...)
- __attribute__ ((__format__ (__printf__, 1, 2)));
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef printf
-# define printf \
- (GL_LINK_WARNING ("printf is not always POSIX compliant - " \
- "use gnulib module printf-posix for portable " \
- "POSIX compliance"), \
- printf)
-/* Don't break __attribute__((format(printf,M,N))). */
-# define format(kind,m,n) format (__##kind##__, m, n)
-# define __format__(kind,m,n) __format__ (__##kind##__, m, n)
-# define ____printf____ __printf__
-# define ____scanf____ __scanf__
-# define ____strftime____ __strftime__
-# define ____strfmon____ __strfmon__
-#endif
-
-#if @GNULIB_VPRINTF_POSIX@
-# if @REPLACE_VPRINTF@
-# define vprintf rpl_vprintf
-extern int vprintf (const char *format, va_list args)
- __attribute__ ((__format__ (__printf__, 1, 0)));
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef vprintf
-# define vprintf(f,a) \
- (GL_LINK_WARNING ("vprintf is not always POSIX compliant - " \
- "use gnulib module vprintf-posix for portable " \
- "POSIX compliance"), \
- vprintf (f, a))
-#endif
-
-#if @GNULIB_SNPRINTF@
-# if @REPLACE_SNPRINTF@
-# define snprintf rpl_snprintf
-# endif
-# if @REPLACE_SNPRINTF@ || !@HAVE_DECL_SNPRINTF@
-extern int snprintf (char *str, size_t size, const char *format, ...)
- __attribute__ ((__format__ (__printf__, 3, 4)));
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef snprintf
-# define snprintf \
- (GL_LINK_WARNING ("snprintf is unportable - " \
- "use gnulib module snprintf for portability"), \
- snprintf)
-#endif
-
-#if @GNULIB_VSNPRINTF@
-# if @REPLACE_VSNPRINTF@
-# define vsnprintf rpl_vsnprintf
-# endif
-# if @REPLACE_VSNPRINTF@ || !@HAVE_DECL_VSNPRINTF@
-extern int vsnprintf (char *str, size_t size, const char *format, va_list args)
- __attribute__ ((__format__ (__printf__, 3, 0)));
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef vsnprintf
-# define vsnprintf(b,s,f,a) \
- (GL_LINK_WARNING ("vsnprintf is unportable - " \
- "use gnulib module vsnprintf for portability"), \
- vsnprintf (b, s, f, a))
-#endif
-
-#if @GNULIB_SPRINTF_POSIX@
-# if @REPLACE_SPRINTF@
-# define sprintf rpl_sprintf
-extern int sprintf (char *str, const char *format, ...)
- __attribute__ ((__format__ (__printf__, 2, 3)));
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef sprintf
-# define sprintf \
- (GL_LINK_WARNING ("sprintf is not always POSIX compliant - " \
- "use gnulib module sprintf-posix for portable " \
- "POSIX compliance"), \
- sprintf)
-#endif
-
-#if @GNULIB_VSPRINTF_POSIX@
-# if @REPLACE_VSPRINTF@
-# define vsprintf rpl_vsprintf
-extern int vsprintf (char *str, const char *format, va_list args)
- __attribute__ ((__format__ (__printf__, 2, 0)));
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef vsprintf
-# define vsprintf(b,f,a) \
- (GL_LINK_WARNING ("vsprintf is not always POSIX compliant - " \
- "use gnulib module vsprintf-posix for portable " \
- "POSIX compliance"), \
- vsprintf (b, f, a))
-#endif
-
-#if @GNULIB_VASPRINTF@
-# if @REPLACE_VASPRINTF@
-# define asprintf rpl_asprintf
-# define vasprintf rpl_vasprintf
-# endif
-# if @REPLACE_VASPRINTF@ || !@HAVE_VASPRINTF@
- /* Write formatted output to a string dynamically allocated with malloc().
- If the memory allocation succeeds, store the address of the string in
- *RESULT and return the number of resulting bytes, excluding the trailing
- NUL. Upon memory allocation error, or some other error, return -1. */
- extern int asprintf (char **result, const char *format, ...)
- __attribute__ ((__format__ (__printf__, 2, 3)));
- extern int vasprintf (char **result, const char *format, va_list args)
- __attribute__ ((__format__ (__printf__, 2, 0)));
-# endif
-#endif
-
-#if @GNULIB_FSEEKO@
-# if @REPLACE_FSEEKO@
-/* Provide fseek, fseeko functions that are aware of a preceding
- fflush(), and which detect pipes. */
-# define fseeko rpl_fseeko
-extern int fseeko (FILE *fp, off_t offset, int whence);
-# define fseek(fp, offset, whence) fseeko (fp, (off_t)(offset), whence)
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef fseeko
-# define fseeko(f,o,w) \
- (GL_LINK_WARNING ("fseeko is unportable - " \
- "use gnulib module fseeko for portability"), \
- fseeko (f, o, w))
-#endif
-
-#if @GNULIB_FSEEK@ && @REPLACE_FSEEK@
-extern int rpl_fseek (FILE *fp, long offset, int whence);
-# undef fseek
-# if defined GNULIB_POSIXCHECK
-# define fseek(f,o,w) \
- (GL_LINK_WARNING ("fseek cannot handle files larger than 4 GB " \
- "on 32-bit platforms - " \
- "use fseeko function for handling of large files"), \
- rpl_fseek (f, o, w))
-# else
-# define fseek rpl_fseek
-# endif
-#elif defined GNULIB_POSIXCHECK
-# ifndef fseek
-# define fseek(f,o,w) \
- (GL_LINK_WARNING ("fseek cannot handle files larger than 4 GB " \
- "on 32-bit platforms - " \
- "use fseeko function for handling of large files"), \
- fseek (f, o, w))
-# endif
-#endif
-
-#if @GNULIB_FTELLO@
-# if @REPLACE_FTELLO@
-# define ftello rpl_ftello
-extern off_t ftello (FILE *fp);
-# define ftell(fp) ftello (fp)
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef ftello
-# define ftello(f) \
- (GL_LINK_WARNING ("ftello is unportable - " \
- "use gnulib module ftello for portability"), \
- ftello (f))
-#endif
-
-#if @GNULIB_FTELL@ && @REPLACE_FTELL@
-extern long rpl_ftell (FILE *fp);
-# undef ftell
-# if GNULIB_POSIXCHECK
-# define ftell(f) \
- (GL_LINK_WARNING ("ftell cannot handle files larger than 4 GB " \
- "on 32-bit platforms - " \
- "use ftello function for handling of large files"), \
- rpl_ftell (f))
-# else
-# define ftell rpl_ftell
-# endif
-#elif defined GNULIB_POSIXCHECK
-# ifndef ftell
-# define ftell(f) \
- (GL_LINK_WARNING ("ftell cannot handle files larger than 4 GB " \
- "on 32-bit platforms - " \
- "use ftello function for handling of large files"), \
- ftell (f))
-# endif
-#endif
-
-#if @GNULIB_FFLUSH@
-# if @REPLACE_FFLUSH@
-# define fflush rpl_fflush
- /* Flush all pending data on STREAM according to POSIX rules. Both
- output and seekable input streams are supported.
- Note! LOSS OF DATA can occur if fflush is applied on an input stream
- that is _not_seekable_ or on an update stream that is _not_seekable_
- and in which the most recent operation was input. Seekability can
- be tested with lseek(fileno(fp),0,SEEK_CUR). */
- extern int fflush (FILE *gl_stream);
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef fflush
-# define fflush(f) \
- (GL_LINK_WARNING ("fflush is not always POSIX compliant - " \
- "use gnulib module fflush for portable " \
- "POSIX compliance"), \
- fflush (f))
-#endif
-
-#if @GNULIB_GETDELIM@
-# if !@HAVE_DECL_GETDELIM@
- /* Read up to (and including) a DELIMITER from FP into *LINEPTR (and
- NUL-terminate it). *LINEPTR is a pointer returned from malloc (or
- NULL), pointing to *N characters of space. It is realloc'ed as
- necessary. Returns the number of characters read (not including
- the null terminator), or -1 on error or EOF. */
- extern ssize_t getdelim (char **, size_t *, int delim, FILE *);
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef getdelim
-# define getdelim(l, s, d, f) \
- (GL_LINK_WARNING ("getdelim is unportable - " \
- "use gnulib module getdelim for portability"), \
- getdelim (l, s, d, f))
-#endif
-
-#if @GNULIB_GETLINE@
-# if @REPLACE_GETLINE@
-# undef getline
-# define getline rpl_getline
-# endif
-# if !@HAVE_DECL_GETLINE@ || @REPLACE_GETLINE@
- /* Read up to (and including) a newline from FP into *LINEPTR (and
- NUL-terminate it). *LINEPTR is a pointer returned from malloc (or
- NULL), pointing to *N characters of space. It is realloc'ed as
- necessary. Returns the number of characters read (not including
- the null terminator), or -1 on error or EOF. */
- extern ssize_t getline (char **, size_t *, FILE *);
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef getline
-# define getline(l, s, f) \
- (GL_LINK_WARNING ("getline is unportable - " \
- "use gnulib module getline for portability"), \
- getline (l, s, f))
-#endif
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* _GL_STDIO_H */
-#endif /* _GL_STDIO_H */
-#endif
diff --git a/gl/string_.h b/gl/string_.h
deleted file mode 100644
index bfb22b0ebc..0000000000
--- a/gl/string_.h
+++ /dev/null
@@ -1,548 +0,0 @@
-/* A GNU-like <string.h>.
-
- Copyright (C) 1995-1996, 2001-2007 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 2, 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_STRING_H
-
-/* The include_next requires a split double-inclusion guard. */
-#@INCLUDE_NEXT@ @NEXT_STRING_H@
-
-#ifndef _GL_STRING_H
-#define _GL_STRING_H
-
-
-/* The definition of GL_LINK_WARNING is copied here. */
-
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/* Return the first occurrence of NEEDLE in HAYSTACK. */
-#if @GNULIB_MEMMEM@
-# if ! @HAVE_DECL_MEMMEM@
-extern void *memmem (void const *__haystack, size_t __haystack_len,
- void const *__needle, size_t __needle_len);
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef memmem
-# define memmem(a,al,b,bl) \
- (GL_LINK_WARNING ("memmem is unportable - " \
- "use gnulib module memmem for portability"), \
- memmem (a, al, b, bl))
-#endif
-
-/* Copy N bytes of SRC to DEST, return pointer to bytes after the
- last written byte. */
-#if @GNULIB_MEMPCPY@
-# if ! @HAVE_MEMPCPY@
-extern void *mempcpy (void *restrict __dest, void const *restrict __src,
- size_t __n);
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef mempcpy
-# define mempcpy(a,b,n) \
- (GL_LINK_WARNING ("mempcpy is unportable - " \
- "use gnulib module mempcpy for portability"), \
- mempcpy (a, b, n))
-#endif
-
-/* Search backwards through a block for a byte (specified as an int). */
-#if @GNULIB_MEMRCHR@
-# if ! @HAVE_DECL_MEMRCHR@
-extern void *memrchr (void const *, int, size_t);
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef memrchr
-# define memrchr(a,b,c) \
- (GL_LINK_WARNING ("memrchr is unportable - " \
- "use gnulib module memrchr for portability"), \
- memrchr (a, b, c))
-#endif
-
-/* Copy SRC to DST, returning the address of the terminating '\0' in DST. */
-#if @GNULIB_STPCPY@
-# if ! @HAVE_STPCPY@
-extern char *stpcpy (char *restrict __dst, char const *restrict __src);
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef stpcpy
-# define stpcpy(a,b) \
- (GL_LINK_WARNING ("stpcpy is unportable - " \
- "use gnulib module stpcpy for portability"), \
- stpcpy (a, b))
-#endif
-
-/* Copy no more than N bytes of SRC to DST, returning a pointer past the
- last non-NUL byte written into DST. */
-#if @GNULIB_STPNCPY@
-# if ! @HAVE_STPNCPY@
-# define stpncpy gnu_stpncpy
-extern char *stpncpy (char *restrict __dst, char const *restrict __src,
- size_t __n);
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef stpncpy
-# define stpncpy(a,b,n) \
- (GL_LINK_WARNING ("stpncpy is unportable - " \
- "use gnulib module stpncpy for portability"), \
- stpncpy (a, b, n))
-#endif
-
-/* Compare strings S1 and S2, ignoring case, returning less than, equal to or
- greater than zero if S1 is lexicographically less than, equal to or greater
- than S2.
- Note: This function does not work in multibyte locales. */
-#if ! @HAVE_STRCASECMP@
-extern int strcasecmp (char const *s1, char const *s2);
-#endif
-#if defined GNULIB_POSIXCHECK
-/* strcasecmp() does not work with multibyte strings:
- POSIX says that it operates on "strings", and "string" in POSIX is defined
- as a sequence of bytes, not of characters. */
-# undef strcasecmp
-# define strcasecmp(a,b) \
- (GL_LINK_WARNING ("strcasecmp cannot work correctly on character strings " \
- "in multibyte locales - " \
- "use mbscasecmp if you care about " \
- "internationalization, or use c_strcasecmp (from " \
- "gnulib module c-strcase) if you want a locale " \
- "independent function"), \
- strcasecmp (a, b))
-#endif
-
-/* Compare no more than N bytes of strings S1 and S2, ignoring case,
- returning less than, equal to or greater than zero if S1 is
- lexicographically less than, equal to or greater than S2.
- Note: This function cannot work correctly in multibyte locales. */
-#if ! @HAVE_DECL_STRNCASECMP@
-extern int strncasecmp (char const *s1, char const *s2, size_t n);
-#endif
-#if defined GNULIB_POSIXCHECK
-/* strncasecmp() does not work with multibyte strings:
- POSIX says that it operates on "strings", and "string" in POSIX is defined
- as a sequence of bytes, not of characters. */
-# undef strncasecmp
-# define strncasecmp(a,b,n) \
- (GL_LINK_WARNING ("strncasecmp cannot work correctly on character " \
- "strings in multibyte locales - " \
- "use mbsncasecmp or mbspcasecmp if you care about " \
- "internationalization, or use c_strncasecmp (from " \
- "gnulib module c-strcase) if you want a locale " \
- "independent function"), \
- strncasecmp (a, b, n))
-#endif
-
-#if defined GNULIB_POSIXCHECK
-/* strchr() does not work with multibyte strings if the locale encoding is
- GB18030 and the character to be searched is a digit. */
-# undef strchr
-# define strchr(s,c) \
- (GL_LINK_WARNING ("strchr cannot work correctly on character strings " \
- "in some multibyte locales - " \
- "use mbschr if you care about internationalization"), \
- strchr (s, c))
-#endif
-
-/* Find the first occurrence of C in S or the final NUL byte. */
-#if @GNULIB_STRCHRNUL@
-# if ! @HAVE_STRCHRNUL@
-extern char *strchrnul (char const *__s, int __c_in);
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef strchrnul
-# define strchrnul(a,b) \
- (GL_LINK_WARNING ("strchrnul is unportable - " \
- "use gnulib module strchrnul for portability"), \
- strchrnul (a, b))
-#endif
-
-/* Duplicate S, returning an identical malloc'd string. */
-#if @GNULIB_STRDUP@
-# if ! @HAVE_DECL_STRDUP@ && ! defined strdup
-extern char *strdup (char const *__s);
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef strdup
-# define strdup(a) \
- (GL_LINK_WARNING ("strdup is unportable - " \
- "use gnulib module strdup for portability"), \
- strdup (a))
-#endif
-
-/* Return a newly allocated copy of at most N bytes of STRING. */
-#if @GNULIB_STRNDUP@
-# if ! @HAVE_STRNDUP@
-# undef strndup
-# define strndup rpl_strndup
-# endif
-# if ! @HAVE_STRNDUP@ || ! @HAVE_DECL_STRNDUP@
-extern char *strndup (char const *__string, size_t __n);
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef strndup
-# define strndup(a,n) \
- (GL_LINK_WARNING ("strndup is unportable - " \
- "use gnulib module strndup for portability"), \
- strndup (a, n))
-#endif
-
-/* Find the length (number of bytes) of STRING, but scan at most
- MAXLEN bytes. If no '\0' terminator is found in that many bytes,
- return MAXLEN. */
-#if @GNULIB_STRNLEN@
-# if ! @HAVE_DECL_STRNLEN@
-extern size_t strnlen (char const *__string, size_t __maxlen);
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef strnlen
-# define strnlen(a,n) \
- (GL_LINK_WARNING ("strnlen is unportable - " \
- "use gnulib module strnlen for portability"), \
- strnlen (a, n))
-#endif
-
-#if defined GNULIB_POSIXCHECK
-/* strcspn() assumes the second argument is a list of single-byte characters.
- Even in this simple case, it does not work with multibyte strings if the
- locale encoding is GB18030 and one of the characters to be searched is a
- digit. */
-# undef strcspn
-# define strcspn(s,a) \
- (GL_LINK_WARNING ("strcspn cannot work correctly on character strings " \
- "in multibyte locales - " \
- "use mbscspn if you care about internationalization"), \
- strcspn (s, a))
-#endif
-
-/* Find the first occurrence in S of any character in ACCEPT. */
-#if @GNULIB_STRPBRK@
-# if ! @HAVE_STRPBRK@
-extern char *strpbrk (char const *__s, char const *__accept);
-# endif
-# if defined GNULIB_POSIXCHECK
-/* strpbrk() assumes the second argument is a list of single-byte characters.
- Even in this simple case, it does not work with multibyte strings if the
- locale encoding is GB18030 and one of the characters to be searched is a
- digit. */
-# undef strpbrk
-# define strpbrk(s,a) \
- (GL_LINK_WARNING ("strpbrk cannot work correctly on character strings " \
- "in multibyte locales - " \
- "use mbspbrk if you care about internationalization"), \
- strpbrk (s, a))
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef strpbrk
-# define strpbrk(s,a) \
- (GL_LINK_WARNING ("strpbrk is unportable - " \
- "use gnulib module strpbrk for portability"), \
- strpbrk (s, a))
-#endif
-
-#if defined GNULIB_POSIXCHECK
-/* strspn() assumes the second argument is a list of single-byte characters.
- Even in this simple case, it cannot work with multibyte strings. */
-# undef strspn
-# define strspn(s,a) \
- (GL_LINK_WARNING ("strspn cannot work correctly on character strings " \
- "in multibyte locales - " \
- "use mbsspn if you care about internationalization"), \
- strspn (s, a))
-#endif
-
-#if defined GNULIB_POSIXCHECK
-/* strrchr() does not work with multibyte strings if the locale encoding is
- GB18030 and the character to be searched is a digit. */
-# undef strrchr
-# define strrchr(s,c) \
- (GL_LINK_WARNING ("strrchr cannot work correctly on character strings " \
- "in some multibyte locales - " \
- "use mbsrchr if you care about internationalization"), \
- strrchr (s, c))
-#endif
-
-/* Search the next delimiter (char listed in DELIM) starting at *STRINGP.
- If one is found, overwrite it with a NUL, and advance *STRINGP
- to point to the next char after it. Otherwise, set *STRINGP to NULL.
- If *STRINGP was already NULL, nothing happens.
- Return the old value of *STRINGP.
-
- This is a variant of strtok() that is multithread-safe and supports
- empty fields.
-
- Caveat: It modifies the original string.
- Caveat: These functions cannot be used on constant strings.
- Caveat: The identity of the delimiting character is lost.
- Caveat: It doesn't work with multibyte strings unless all of the delimiter
- characters are ASCII characters < 0x30.
-
- See also strtok_r(). */
-#if @GNULIB_STRSEP@
-# if ! @HAVE_STRSEP@
-extern char *strsep (char **restrict __stringp, char const *restrict __delim);
-# endif
-# if defined GNULIB_POSIXCHECK
-# undef strsep
-# define strsep(s,d) \
- (GL_LINK_WARNING ("strsep cannot work correctly on character strings " \
- "in multibyte locales - " \
- "use mbssep if you care about internationalization"), \
- strsep (s, d))
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef strsep
-# define strsep(s,d) \
- (GL_LINK_WARNING ("strsep is unportable - " \
- "use gnulib module strsep for portability"), \
- strsep (s, d))
-#endif
-
-#if defined GNULIB_POSIXCHECK
-/* strstr() does not work with multibyte strings if the locale encoding is
- different from UTF-8:
- POSIX says that it operates on "strings", and "string" in POSIX is defined
- as a sequence of bytes, not of characters. */
-# undef strstr
-# define strstr(a,b) \
- (GL_LINK_WARNING ("strstr cannot work correctly on character strings " \
- "in most multibyte locales - " \
- "use mbsstr if you care about internationalization"), \
- strstr (a, b))
-#endif
-
-/* Find the first occurrence of NEEDLE in HAYSTACK, using case-insensitive
- comparison. */
-#if ! @HAVE_STRCASESTR@
-extern char *strcasestr (const char *haystack, const char *needle);
-#endif
-#if defined GNULIB_POSIXCHECK
-/* strcasestr() does not work with multibyte strings:
- It is a glibc extension, and glibc implements it only for unibyte
- locales. */
-# undef strcasestr
-# define strcasestr(a,b) \
- (GL_LINK_WARNING ("strcasestr does work correctly on character strings " \
- "in multibyte locales - " \
- "use mbscasestr if you care about " \
- "internationalization, or use c-strcasestr if you want " \
- "a locale independent function"), \
- strcasestr (a, b))
-#endif
-
-/* Parse S into tokens separated by characters in DELIM.
- If S is NULL, the saved pointer in SAVE_PTR is used as
- the next starting point. For example:
- char s[] = "-abc-=-def";
- char *sp;
- x = strtok_r(s, "-", &sp); // x = "abc", sp = "=-def"
- x = strtok_r(NULL, "-=", &sp); // x = "def", sp = NULL
- x = strtok_r(NULL, "=", &sp); // x = NULL
- // s = "abc\0-def\0"
-
- This is a variant of strtok() that is multithread-safe.
-
- For the POSIX documentation for this function, see:
- http://www.opengroup.org/susv3xsh/strtok.html
-
- Caveat: It modifies the original string.
- Caveat: These functions cannot be used on constant strings.
- Caveat: The identity of the delimiting character is lost.
- Caveat: It doesn't work with multibyte strings unless all of the delimiter
- characters are ASCII characters < 0x30.
-
- See also strsep(). */
-#if @GNULIB_STRTOK_R@
-# if ! @HAVE_DECL_STRTOK_R@
-extern char *strtok_r (char *restrict s, char const *restrict delim,
- char **restrict save_ptr);
-# endif
-# if defined GNULIB_POSIXCHECK
-# undef strtok_r
-# define strtok_r(s,d,p) \
- (GL_LINK_WARNING ("strtok_r cannot work correctly on character strings " \
- "in multibyte locales - " \
- "use mbstok_r if you care about internationalization"), \
- strtok_r (s, d, p))
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef strtok_r
-# define strtok_r(s,d,p) \
- (GL_LINK_WARNING ("strtok_r is unportable - " \
- "use gnulib module strtok_r for portability"), \
- strtok_r (s, d, p))
-#endif
-
-
-/* The following functions are not specified by POSIX. They are gnulib
- extensions. */
-
-#if @GNULIB_MBSLEN@
-/* Return the number of multibyte characters in the character string STRING.
- This considers multibyte characters, unlike strlen, which counts bytes. */
-extern size_t mbslen (const char *string);
-#endif
-
-#if @GNULIB_MBSNLEN@
-/* Return the number of multibyte characters in the character string starting
- at STRING and ending at STRING + LEN. */
-extern size_t mbsnlen (const char *string, size_t len);
-#endif
-
-#if @GNULIB_MBSCHR@
-/* Locate the first single-byte character C in the character string STRING,
- and return a pointer to it. Return NULL if C is not found in STRING.
- Unlike strchr(), this function works correctly in multibyte locales with
- encodings such as GB18030. */
-# define mbschr rpl_mbschr /* avoid collision with HP-UX function */
-extern char * mbschr (const char *string, int c);
-#endif
-
-#if @GNULIB_MBSRCHR@
-/* Locate the last single-byte character C in the character string STRING,
- and return a pointer to it. Return NULL if C is not found in STRING.
- Unlike strrchr(), this function works correctly in multibyte locales with
- encodings such as GB18030. */
-# define mbsrchr rpl_mbsrchr /* avoid collision with HP-UX function */
-extern char * mbsrchr (const char *string, int c);
-#endif
-
-#if @GNULIB_MBSSTR@
-/* Find the first occurrence of the character string NEEDLE in the character
- string HAYSTACK. Return NULL if NEEDLE is not found in HAYSTACK.
- Unlike strstr(), this function works correctly in multibyte locales with
- encodings different from UTF-8. */
-extern char * mbsstr (const char *haystack, const char *needle);
-#endif
-
-#if @GNULIB_MBSCASECMP@
-/* Compare the character strings S1 and S2, ignoring case, returning less than,
- equal to or greater than zero if S1 is lexicographically less than, equal to
- or greater than S2.
- Note: This function may, in multibyte locales, return 0 for strings of
- different lengths!
- Unlike strcasecmp(), this function works correctly in multibyte locales. */
-extern int mbscasecmp (const char *s1, const char *s2);
-#endif
-
-#if @GNULIB_MBSNCASECMP@
-/* Compare the initial segment of the character string S1 consisting of at most
- N characters with the initial segment of the character string S2 consisting
- of at most N characters, ignoring case, returning less than, equal to or
- greater than zero if the initial segment of S1 is lexicographically less
- than, equal to or greater than the initial segment of S2.
- Note: This function may, in multibyte locales, return 0 for initial segments
- of different lengths!
- Unlike strncasecmp(), this function works correctly in multibyte locales.
- But beware that N is not a byte count but a character count! */
-extern int mbsncasecmp (const char *s1, const char *s2, size_t n);
-#endif
-
-#if @GNULIB_MBSPCASECMP@
-/* Compare the initial segment of the character string STRING consisting of
- at most mbslen (PREFIX) characters with the character string PREFIX,
- ignoring case, returning less than, equal to or greater than zero if this
- initial segment is lexicographically less than, equal to or greater than
- PREFIX.
- Note: This function may, in multibyte locales, return 0 if STRING is of
- smaller length than PREFIX!
- Unlike strncasecmp(), this function works correctly in multibyte
- locales. */
-extern char * mbspcasecmp (const char *string, const char *prefix);
-#endif
-
-#if @GNULIB_MBSCASESTR@
-/* Find the first occurrence of the character string NEEDLE in the character
- string HAYSTACK, using case-insensitive comparison.
- Note: This function may, in multibyte locales, return success even if
- strlen (haystack) < strlen (needle) !
- Unlike strcasestr(), this function works correctly in multibyte locales. */
-extern char * mbscasestr (const char *haystack, const char *needle);
-#endif
-
-#if @GNULIB_MBSCSPN@
-/* Find the first occurrence in the character string STRING of any character
- in the character string ACCEPT. Return the number of bytes from the
- beginning of the string to this occurrence, or to the end of the string
- if none exists.
- Unlike strcspn(), this function works correctly in multibyte locales. */
-extern size_t mbscspn (const char *string, const char *accept);
-#endif
-
-#if @GNULIB_MBSPBRK@
-/* Find the first occurrence in the character string STRING of any character
- in the character string ACCEPT. Return the pointer to it, or NULL if none
- exists.
- Unlike strpbrk(), this function works correctly in multibyte locales. */
-# define mbspbrk rpl_mbspbrk /* avoid collision with HP-UX function */
-extern char * mbspbrk (const char *string, const char *accept);
-#endif
-
-#if @GNULIB_MBSSPN@
-/* Find the first occurrence in the character string STRING of any character
- not in the character string REJECT. Return the number of bytes from the
- beginning of the string to this occurrence, or to the end of the string
- if none exists.
- Unlike strspn(), this function works correctly in multibyte locales. */
-extern size_t mbsspn (const char *string, const char *reject);
-#endif
-
-#if @GNULIB_MBSSEP@
-/* Search the next delimiter (multibyte character listed in the character
- string DELIM) starting at the character string *STRINGP.
- If one is found, overwrite it with a NUL, and advance *STRINGP to point
- to the next multibyte character after it. Otherwise, set *STRINGP to NULL.
- If *STRINGP was already NULL, nothing happens.
- Return the old value of *STRINGP.
-
- This is a variant of mbstok_r() that supports empty fields.
-
- Caveat: It modifies the original string.
- Caveat: These functions cannot be used on constant strings.
- Caveat: The identity of the delimiting character is lost.
-
- See also mbstok_r(). */
-extern char * mbssep (char **stringp, const char *delim);
-#endif
-
-#if @GNULIB_MBSTOK_R@
-/* Parse the character string STRING into tokens separated by characters in
- the character string DELIM.
- If STRING is NULL, the saved pointer in SAVE_PTR is used as
- the next starting point. For example:
- char s[] = "-abc-=-def";
- char *sp;
- x = mbstok_r(s, "-", &sp); // x = "abc", sp = "=-def"
- x = mbstok_r(NULL, "-=", &sp); // x = "def", sp = NULL
- x = mbstok_r(NULL, "=", &sp); // x = NULL
- // s = "abc\0-def\0"
-
- Caveat: It modifies the original string.
- Caveat: These functions cannot be used on constant strings.
- Caveat: The identity of the delimiting character is lost.
-
- See also mbssep(). */
-extern char * mbstok_r (char *string, const char *delim, char **save_ptr);
-#endif
-
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* _GL_STRING_H */
-#endif /* _GL_STRING_H */
diff --git a/gl/sys_socket_.h b/gl/sys_socket_.h
deleted file mode 100644
index c25b6ab842..0000000000
--- a/gl/sys_socket_.h
+++ /dev/null
@@ -1,91 +0,0 @@
-/* Provide a sys/socket header file for systems lacking it (read: MinGW).
- Copyright (C) 2005, 2006, 2007 Free Software Foundation, Inc.
- Written by Simon Josefsson.
-
- 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 2, 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. */
-
-/* This file is supposed to be used on platforms that lack <sys/socket.h>
- and on platforms where <sys/socket.h> cannot be included standalone.
- It is intended to provide definitions and prototypes needed by an
- application. */
-
-#ifndef _GL_SYS_SOCKET_H
-
-#if @HAVE_SYS_SOCKET_H@
-
-/* On many platforms, <sys/socket.h> assumes prior inclusion of
- <sys/types.h>. */
-# include <sys/types.h>
-
-/* The include_next requires a split double-inclusion guard. */
-# @INCLUDE_NEXT@ @NEXT_SYS_SOCKET_H@
-
-#endif
-
-#ifndef _GL_SYS_SOCKET_H
-#define _GL_SYS_SOCKET_H
-
-#if !@HAVE_SYS_SOCKET_H@
-
-/* A platform that lacks <sys/socket.h>.
-
- Currently only MinGW is supported. See the gnulib manual regarding
- Windows sockets. MinGW has the header files winsock2.h and
- ws2tcpip.h that declare the sys/socket.h definitions we need. Note
- that you can influence which definitions you get by setting the
- WINVER symbol before including these two files. For example,
- getaddrinfo is only available if _WIN32_WINNT >= 0x0501 (that
- symbol is set indiriectly through WINVER). You can set this by
- adding AC_DEFINE(WINVER, 0x0501) to configure.ac. Note that your
- code may not run on older Windows releases then. My Windows 2000
- box was not able to run the code, for example. The situation is
- slightly confusing because:
- http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winsock/winsock/getaddrinfo_2.asp
- suggests that getaddrinfo should be available on all Windows
- releases. */
-
-
-# if @HAVE_WINSOCK2_H@
-# include <winsock2.h>
-# endif
-# if @HAVE_WS2TCPIP_H@
-# include <ws2tcpip.h>
-# endif
-
-/* For shutdown(). */
-# if !defined SHUT_RD && defined SD_RECEIVE
-# define SHUT_RD SD_RECEIVE
-# endif
-# if !defined SHUT_WR && defined SD_SEND
-# define SHUT_WR SD_SEND
-# endif
-# if !defined SHUT_RDWR && defined SD_BOTH
-# define SHUT_RDWR SD_BOTH
-# endif
-
-# if defined _WIN32 || defined __WIN32__
-# define ENOTSOCK WSAENOTSOCK
-# define EADDRINUSE WSAEADDRINUSE
-# define ENETRESET WSAENETRESET
-# define ECONNABORTED WSAECONNABORTED
-# define ECONNRESET WSAECONNRESET
-# define ENOTCONN WSAENOTCONN
-# define ESHUTDOWN WSAESHUTDOWN
-# endif
-
-#endif /* HAVE_SYS_SOCKET_H */
-
-#endif /* _GL_SYS_SOCKET_H */
-#endif /* _GL_SYS_SOCKET_H */
diff --git a/gl/unistd_.h b/gl/unistd_.h
deleted file mode 100644
index 07c4877836..0000000000
--- a/gl/unistd_.h
+++ /dev/null
@@ -1,262 +0,0 @@
-/* Substitute for and wrapper around <unistd.h>.
- Copyright (C) 2004-2007 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 2, 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_UNISTD_H
-
-/* The include_next requires a split double-inclusion guard. */
-#if @HAVE_UNISTD_H@
-# @INCLUDE_NEXT@ @NEXT_UNISTD_H@
-#endif
-
-#ifndef _GL_UNISTD_H
-#define _GL_UNISTD_H
-
-/* mingw doesn't define the SEEK_* macros in <unistd.h>. */
-#if !(defined SEEK_CUR && defined SEEK_END && defined SEEK_SET)
-# include <stdio.h>
-#endif
-
-/* mingw fails to declare _exit in <unistd.h>. */
-#include <stdlib.h>
-
-/* The definition of GL_LINK_WARNING is copied here. */
-
-
-/* Declare overridden functions. */
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-
-#if @GNULIB_CHOWN@
-# if @REPLACE_CHOWN@
-# ifndef REPLACE_CHOWN
-# define REPLACE_CHOWN 1
-# endif
-# if REPLACE_CHOWN
-/* Change the owner of FILE to UID (if UID is not -1) and the group of FILE
- to GID (if GID is not -1). Follow symbolic links.
- Return 0 if successful, otherwise -1 and errno set.
- See the POSIX:2001 specification
- <http://www.opengroup.org/susv3xsh/chown.html>. */
-# define chown rpl_chown
-extern int chown (const char *file, uid_t uid, gid_t gid);
-# endif
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef chown
-# define chown(f,u,g) \
- (GL_LINK_WARNING ("chown fails to follow symlinks on some systems and " \
- "doesn't treat a uid or gid of -1 on some systems - " \
- "use gnulib module chown for portability"), \
- chown (f, u, g))
-#endif
-
-
-#if @GNULIB_DUP2@
-# if !@HAVE_DUP2@
-/* Copy the file descriptor OLDFD into file descriptor NEWFD. Do nothing if
- NEWFD = OLDFD, otherwise close NEWFD first if it is open.
- Return 0 if successful, otherwise -1 and errno set.
- See the POSIX:2001 specification
- <http://www.opengroup.org/susv3xsh/dup2.html>. */
-extern int dup2 (int oldfd, int newfd);
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef dup2
-# define dup2(o,n) \
- (GL_LINK_WARNING ("dup2 is unportable - " \
- "use gnulib module dup2 for portability"), \
- dup2 (o, n))
-#endif
-
-
-#if @GNULIB_FCHDIR@
-# if @REPLACE_FCHDIR@
-
-/* Change the process' current working directory to the directory on which
- the given file descriptor is open.
- Return 0 if successful, otherwise -1 and errno set.
- See the POSIX:2001 specification
- <http://www.opengroup.org/susv3xsh/fchdir.html>. */
-extern int fchdir (int /*fd*/);
-
-# define close rpl_close
-extern int close (int);
-# define dup rpl_dup
-extern int dup (int);
-# define dup2 rpl_dup2
-extern int dup2 (int, int);
-
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef fchdir
-# define fchdir(f) \
- (GL_LINK_WARNING ("fchdir is unportable - " \
- "use gnulib module fchdir for portability"), \
- fchdir (f))
-#endif
-
-
-#if @GNULIB_FTRUNCATE@
-# if !@HAVE_FTRUNCATE@
-/* Change the size of the file to which FD is opened to become equal to LENGTH.
- Return 0 if successful, otherwise -1 and errno set.
- See the POSIX:2001 specification
- <http://www.opengroup.org/susv3xsh/ftruncate.html>. */
-extern int ftruncate (int fd, off_t length);
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef ftruncate
-# define ftruncate(f,l) \
- (GL_LINK_WARNING ("ftruncate is unportable - " \
- "use gnulib module ftruncate for portability"), \
- ftruncate (f, l))
-#endif
-
-
-#if @GNULIB_GETCWD@
-/* Include the headers that might declare getcwd so that they will not
- cause confusion if included after this file. */
-# include <stdlib.h>
-# if @REPLACE_GETCWD@
-/* Get the name of the current working directory, and put it in SIZE bytes
- of BUF.
- Return BUF if successful, or NULL if the directory couldn't be determined
- or SIZE was too small.
- See the POSIX:2001 specification
- <http://www.opengroup.org/susv3xsh/getcwd.html>.
- Additionally, the gnulib module 'getcwd' guarantees the following GNU
- extension: If BUF is NULL, an array is allocated with 'malloc'; the array
- is SIZE bytes long, unless SIZE == 0, in which case it is as big as
- necessary. */
-# define getcwd rpl_getcwd
-extern char * getcwd (char *buf, size_t size);
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef getcwd
-# define getcwd(b,s) \
- (GL_LINK_WARNING ("getcwd is unportable - " \
- "use gnulib module getcwd for portability"), \
- getcwd (b, s))
-#endif
-
-
-#if @GNULIB_GETLOGIN_R@
-/* Copies the user's login name to NAME.
- The array pointed to by NAME has room for SIZE bytes.
-
- Returns 0 if successful. Upon error, an error number is returned, or -1 in
- the case that the login name cannot be found but no specific error is
- provided (this case is hopefully rare but is left open by the POSIX spec).
-
- See <http://www.opengroup.org/susv3xsh/getlogin.html>.
- */
-# if !@HAVE_DECL_GETLOGIN_R@
-# include <stddef.h>
-extern int getlogin_r (char *name, size_t size);
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef getlogin_r
-# define getlogin_r(n,s) \
- (GL_LINK_WARNING ("getlogin_r is unportable - " \
- "use gnulib module getlogin_r for portability"), \
- getlogin_r (n, s))
-#endif
-
-
-#if @GNULIB_LCHOWN@
-# if @REPLACE_LCHOWN@
-/* Change the owner of FILE to UID (if UID is not -1) and the group of FILE
- to GID (if GID is not -1). Do not follow symbolic links.
- Return 0 if successful, otherwise -1 and errno set.
- See the POSIX:2001 specification
- <http://www.opengroup.org/susv3xsh/lchown.html>. */
-# define lchown rpl_lchown
-extern int lchown (char const *file, uid_t owner, gid_t group);
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef lchown
-# define lchown(f,u,g) \
- (GL_LINK_WARNING ("lchown is unportable to pre-POSIX.1-2001 " \
- "systems - use gnulib module lchown for portability"), \
- lchown (f, u, g))
-#endif
-
-
-#if @GNULIB_LSEEK@
-# if @REPLACE_LSEEK@
-/* Set the offset of FD relative to SEEK_SET, SEEK_CUR, or SEEK_END.
- Return the new offset if successful, otherwise -1 and errno set.
- See the POSIX:2001 specification
- <http://www.opengroup.org/susv3xsh/lseek.html>. */
-# define lseek rpl_lseek
- extern off_t lseek (int fd, off_t offset, int whence);
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef lseek
-# define lseek(f,o,w) \
- (GL_LINK_WARNING ("lseek does not fail with ESPIPE on pipes on some " \
- "systems - use gnulib module lseek for portability"), \
- lseek (f, o, w))
-#endif
-
-
-#if @GNULIB_READLINK@
-/* Read the contents of the symbolic link FILE and place the first BUFSIZE
- bytes of it into BUF. Return the number of bytes placed into BUF if
- successful, otherwise -1 and errno set.
- See the POSIX:2001 specification
- <http://www.opengroup.org/susv3xsh/readlink.html>. */
-# if !@HAVE_READLINK@
-# include <stddef.h>
-extern int readlink (const char *file, char *buf, size_t bufsize);
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef readlink
-# define readlink(f,b,s) \
- (GL_LINK_WARNING ("readlink is unportable - " \
- "use gnulib module readlink for portability"), \
- readlink (f, b, s))
-#endif
-
-
-#if @GNULIB_SLEEP@
-/* Pause the execution of the current thread for N seconds.
- Returns the number of seconds left to sleep.
- See the POSIX:2001 specification
- <http://www.opengroup.org/susv3xsh/sleep.html>. */
-# if !@HAVE_SLEEP@
-extern unsigned int sleep (unsigned int n);
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef sleep
-# define sleep(n) \
- (GL_LINK_WARNING ("sleep is unportable - " \
- "use gnulib module sleep for portability"), \
- sleep (n))
-#endif
-
-
-#ifdef __cplusplus
-}
-#endif
-
-
-#endif /* _GL_UNISTD_H */
-#endif /* _GL_UNISTD_H */
diff --git a/guile/src/core.c b/guile/src/core.c
index dc27d2369e..217ccede7e 100644
--- a/guile/src/core.c
+++ b/guile/src/core.c
@@ -2380,7 +2380,8 @@ SCM_DEFINE (scm_gnutls_x509_certificate_issuer_dn,
if (c_oid_actual_len < c_oid_len) \
c_oid = scm_realloc (c_oid, c_oid_actual_len); \
\
- result = scm_take_locale_string (c_oid); \
+ result = scm_take_locale_stringn (c_oid, \
+ c_oid_actual_len); \
} \
\
return result;
diff --git a/includes/.cvsignore b/includes/.cvsignore
deleted file mode 100644
index 282522db03..0000000000
--- a/includes/.cvsignore
+++ /dev/null
@@ -1,2 +0,0 @@
-Makefile
-Makefile.in
diff --git a/includes/gnutls/.cvsignore b/includes/gnutls/.cvsignore
deleted file mode 100644
index 6c4ae366b1..0000000000
--- a/includes/gnutls/.cvsignore
+++ /dev/null
@@ -1,3 +0,0 @@
-Makefile
-Makefile.in
-gnutls.h
diff --git a/lgl/.cvsignore b/lgl/.cvsignore
deleted file mode 100644
index ac19279beb..0000000000
--- a/lgl/.cvsignore
+++ /dev/null
@@ -1,23 +0,0 @@
-.deps
-.libs
-Makefile
-Makefile.in
-liblgnu.la
-*.lo
-alloca.h
-stdint.h
-string.h
-sys
-time.h
-stdio.h
-unistd.h
-float+.h
-getdelim.c
-getdelim.h
-getline.c
-getline.h
-getpass.c
-getpass.h
-float_.h
-fseeko.c
-lseek.c
diff --git a/lgl/Makefile.am b/lgl/Makefile.am
index 53d78248a6..703701a48a 100644
--- a/lgl/Makefile.am
+++ b/lgl/Makefile.am
@@ -35,6 +35,15 @@ liblgnu_la_DEPENDENCIES = $(lgl_LTLIBOBJS)
EXTRA_liblgnu_la_SOURCES =
liblgnu_la_LDFLAGS = $(AM_LDFLAGS)
+## begin gnulib module absolute-header
+
+# Use this preprocessor expression to decide whether #include_next works.
+# Do not rely on a 'configure'-time test for this, since the expression
+# might appear in an installed header, which is used by some other compiler.
+HAVE_INCLUDE_NEXT = (__GNUC__ || 60000000 <= __DECC_VER)
+
+## end gnulib module absolute-header
+
## begin gnulib module alloca-opt
BUILT_SOURCES += $(ALLOCA_H)
@@ -254,6 +263,15 @@ EXTRA_liblgnu_la_SOURCES += read-file.c
## end gnulib module read-file
+## begin gnulib module realloc-posix
+
+
+EXTRA_DIST += realloc.c
+
+EXTRA_liblgnu_la_SOURCES += realloc.c
+
+## end gnulib module realloc-posix
+
## begin gnulib module size_max
liblgnu_la_SOURCES += size_max.h
@@ -384,6 +402,39 @@ EXTRA_DIST += stdio_.h
## end gnulib module stdio
+## begin gnulib module stdlib
+
+BUILT_SOURCES += stdlib.h
+
+# We need the following in order to create <stdlib.h> when the system
+# doesn't have one that works with the given compiler.
+stdlib.h: stdlib_.h
+ rm -f $@-t $@
+ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \
+ sed -e 's/@''INCLUDE_NEXT''@/$(INCLUDE_NEXT)/g' \
+ -e 's|@''NEXT_STDLIB_H''@|$(NEXT_STDLIB_H)|g' \
+ -e 's|@''GNULIB_MALLOC_POSIX''@|$(GNULIB_MALLOC_POSIX)|g' \
+ -e 's|@''GNULIB_REALLOC_POSIX''@|$(GNULIB_REALLOC_POSIX)|g' \
+ -e 's|@''GNULIB_CALLOC_POSIX''@|$(GNULIB_CALLOC_POSIX)|g' \
+ -e 's|@''GNULIB_GETSUBOPT''@|$(GNULIB_GETSUBOPT)|g' \
+ -e 's|@''GNULIB_MKDTEMP''@|$(GNULIB_MKDTEMP)|g' \
+ -e 's|@''GNULIB_MKSTEMP''@|$(GNULIB_MKSTEMP)|g' \
+ -e 's|@''HAVE_CALLOC_POSIX''@|$(HAVE_CALLOC_POSIX)|g' \
+ -e 's|@''HAVE_GETSUBOPT''@|$(HAVE_GETSUBOPT)|g' \
+ -e 's|@''HAVE_MALLOC_POSIX''@|$(HAVE_MALLOC_POSIX)|g' \
+ -e 's|@''HAVE_MKDTEMP''@|$(HAVE_MKDTEMP)|g' \
+ -e 's|@''HAVE_REALLOC_POSIX''@|$(HAVE_REALLOC_POSIX)|g' \
+ -e 's|@''REPLACE_MKSTEMP''@|$(REPLACE_MKSTEMP)|g' \
+ -e '/definition of GL_LINK_WARNING/r $(LINK_WARNING_H)' \
+ < $(srcdir)/stdlib_.h; \
+ } > $@-t
+ mv $@-t $@
+MOSTLYCLEANFILES += stdlib.h stdlib.h-t
+
+EXTRA_DIST += stdlib_.h
+
+## end gnulib module stdlib
+
## begin gnulib module string
BUILT_SOURCES += string.h
diff --git a/lgl/m4/absolute-header.m4 b/lgl/m4/absolute-header.m4
new file mode 100644
index 0000000000..5b7a2fc35f
--- /dev/null
+++ b/lgl/m4/absolute-header.m4
@@ -0,0 +1,49 @@
+# absolute-header.m4 serial 7
+dnl Copyright (C) 2006, 2007 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, assuming 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.
+AC_DEFUN([gl_ABSOLUTE_HEADER],
+[AC_LANG_PREPROC_REQUIRE()dnl
+AC_FOREACH([gl_HEADER_NAME], [$1],
+ [AS_VAR_PUSHDEF([gl_absolute_header],
+ [gl_cv_absolute_]m4_quote(m4_defn([gl_HEADER_NAME])))dnl
+ AC_CACHE_CHECK([absolute name of <]m4_quote(m4_defn([gl_HEADER_NAME]))[>],
+ m4_quote(m4_defn([gl_absolute_header])),
+ [AS_VAR_PUSHDEF([ac_header_exists],
+ [ac_cv_header_]m4_quote(m4_defn([gl_HEADER_NAME])))dnl
+ AC_CHECK_HEADERS_ONCE(m4_quote(m4_defn([gl_HEADER_NAME])))dnl
+ if test AS_VAR_GET(ac_header_exists) = yes; then
+ AC_LANG_CONFTEST([AC_LANG_SOURCE([[#include <]]m4_dquote(m4_defn([gl_HEADER_NAME]))[[>]])])
+dnl eval is necessary to expand ac_cpp.
+dnl Ultrix and Pyramid sh refuse to redirect output of eval, so use subshell.
+ AS_VAR_SET(gl_absolute_header,
+[`(eval "$ac_cpp conftest.$ac_ext") 2>&AS_MESSAGE_LOG_FD |
+sed -n '\#/]m4_quote(m4_defn([gl_HEADER_NAME]))[#{
+ s#.*"\(.*/]m4_quote(m4_defn([gl_HEADER_NAME]))[\)".*#\1#
+ s#^/[^/]#//&#
+ p
+ q
+}'`])
+ fi
+ AS_VAR_POPDEF([ac_header_exists])dnl
+ ])dnl
+ AC_DEFINE_UNQUOTED(AS_TR_CPP([ABSOLUTE_]m4_quote(m4_defn([gl_HEADER_NAME]))),
+ ["AS_VAR_GET(gl_absolute_header)"],
+ [Define this to an absolute name of <]m4_quote(m4_defn([gl_HEADER_NAME]))[>.])
+ AS_VAR_POPDEF([gl_absolute_header])dnl
+])dnl
+])# gl_ABSOLUTE_HEADER
diff --git a/lgl/m4/gnulib-comp.m4 b/lgl/m4/gnulib-comp.m4
index b9078478e0..10e3e26fe8 100644
--- a/lgl/m4/gnulib-comp.m4
+++ b/lgl/m4/gnulib-comp.m4
@@ -79,6 +79,8 @@ AC_DEFUN([lgl_INIT],
gl_FUNC_MEMMOVE
gl_MINMAX
gl_FUNC_READ_FILE
+ gl_FUNC_REALLOC_POSIX
+ gl_STDLIB_MODULE_INDICATOR([realloc-posix])
gl_SIZE_MAX
gl_FUNC_SNPRINTF
gl_STDIO_MODULE_INDICATOR([snprintf])
@@ -86,6 +88,7 @@ AC_DEFUN([lgl_INIT],
AM_STDBOOL_H
gl_STDINT_H
gl_STDIO_H
+ gl_STDLIB_H
gl_HEADER_STRING_H
gl_FUNC_STRVERSCMP
gl_HEADER_SYS_SOCKET
@@ -176,6 +179,7 @@ AC_DEFUN([lgl_FILE_LIST], [
lib/printf-parse.h
lib/read-file.c
lib/read-file.h
+ lib/realloc.c
lib/rijndael-alg-fst.c
lib/rijndael-alg-fst.h
lib/rijndael-api-fst.c
@@ -187,6 +191,7 @@ AC_DEFUN([lgl_FILE_LIST], [
lib/stdbool_.h
lib/stdint_.h
lib/stdio_.h
+ lib/stdlib_.h
lib/string_.h
lib/strverscmp.c
lib/strverscmp.h
@@ -200,6 +205,7 @@ AC_DEFUN([lgl_FILE_LIST], [
lib/vasprintf.c
lib/wchar_.h
lib/xsize.h
+ m4/absolute-header.m4
m4/alloca.m4
m4/arcfour.m4
m4/arctwo.m4
@@ -243,6 +249,7 @@ AC_DEFUN([lgl_FILE_LIST], [
m4/lib-prefix.m4
m4/lock.m4
m4/longlong.m4
+ m4/malloc.m4
m4/md2.m4
m4/md4.m4
m4/md5.m4
@@ -255,6 +262,7 @@ AC_DEFUN([lgl_FILE_LIST], [
m4/printf-posix.m4
m4/progtest.m4
m4/read-file.m4
+ m4/realloc.m4
m4/rijndael.m4
m4/sha1.m4
m4/size_max.m4
@@ -265,6 +273,7 @@ AC_DEFUN([lgl_FILE_LIST], [
m4/stdint.m4
m4/stdint_h.m4
m4/stdio_h.m4
+ m4/stdlib_h.m4
m4/string_h.m4
m4/strverscmp.m4
m4/sys_socket_h.m4
diff --git a/lgl/m4/malloc.m4 b/lgl/m4/malloc.m4
new file mode 100644
index 0000000000..764f2a9fa1
--- /dev/null
+++ b/lgl/m4/malloc.m4
@@ -0,0 +1,41 @@
+# malloc.m4 serial 8
+dnl Copyright (C) 2007 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.
+
+# gl_FUNC_MALLOC_POSIX
+# --------------------
+# Test whether 'malloc' is POSIX compliant (sets errno to ENOMEM when it
+# fails), and replace malloc if it is not.
+AC_DEFUN([gl_FUNC_MALLOC_POSIX],
+[
+ AC_REQUIRE([gl_CHECK_MALLOC_POSIX])
+ if test $gl_cv_func_malloc_posix = yes; then
+ HAVE_MALLOC_POSIX=1
+ AC_DEFINE([HAVE_MALLOC_POSIX], 1,
+ [Define if the 'malloc' function is POSIX compliant.])
+ else
+ AC_LIBOBJ([malloc])
+ HAVE_MALLOC_POSIX=0
+ fi
+ AC_SUBST([HAVE_MALLOC_POSIX])
+])
+
+# Test whether malloc, realloc, calloc are POSIX compliant,
+# Set gl_cv_func_malloc_posix to yes or no accordingly.
+AC_DEFUN([gl_CHECK_MALLOC_POSIX],
+[
+ AC_CACHE_CHECK([whether malloc, realloc, calloc are POSIX compliant],
+ [gl_cv_func_malloc_posix],
+ [
+ dnl It is too dangerous to try to allocate a large amount of memory:
+ dnl some systems go to their knees when you do that. So assume that
+ dnl all Unix implementations of the function are POSIX compliant.
+ AC_TRY_COMPILE([],
+ [#if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
+ choke me
+ #endif
+ ], [gl_cv_func_malloc_posix=yes], [gl_cv_func_malloc_posix=no])
+ ])
+])
diff --git a/lgl/m4/realloc.m4 b/lgl/m4/realloc.m4
new file mode 100644
index 0000000000..f9fd935dbb
--- /dev/null
+++ b/lgl/m4/realloc.m4
@@ -0,0 +1,23 @@
+# realloc.m4 serial 8
+dnl Copyright (C) 2007 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.
+
+# gl_FUNC_REALLOC_POSIX
+# ---------------------
+# Test whether 'realloc' is POSIX compliant (sets errno to ENOMEM when it
+# fails), and replace realloc if it is not.
+AC_DEFUN([gl_FUNC_REALLOC_POSIX],
+[
+ AC_REQUIRE([gl_CHECK_MALLOC_POSIX])
+ if test $gl_cv_func_malloc_posix = yes; then
+ HAVE_REALLOC_POSIX=1
+ AC_DEFINE([HAVE_REALLOC_POSIX], 1,
+ [Define if the 'realloc' function is POSIX compliant.])
+ else
+ AC_LIBOBJ([realloc])
+ HAVE_REALLOC_POSIX=0
+ fi
+ AC_SUBST([HAVE_REALLOC_POSIX])
+])
diff --git a/lgl/m4/stdlib_h.m4 b/lgl/m4/stdlib_h.m4
new file mode 100644
index 0000000000..ea9286ef46
--- /dev/null
+++ b/lgl/m4/stdlib_h.m4
@@ -0,0 +1,35 @@
+# stdlib_h.m4 serial 3
+dnl Copyright (C) 2007 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_STDLIB_H],
+[
+ AC_REQUIRE([gl_STDLIB_H_DEFAULTS])
+ gl_CHECK_NEXT_HEADERS([stdlib.h])
+])
+
+AC_DEFUN([gl_STDLIB_MODULE_INDICATOR],
+[
+ dnl Use AC_REQUIRE here, so that the default settings are expanded once only.
+ AC_REQUIRE([gl_STDLIB_H_DEFAULTS])
+ GNULIB_[]m4_translit([$1],[abcdefghijklmnopqrstuvwxyz./-],[ABCDEFGHIJKLMNOPQRSTUVWXYZ___])=1
+])
+
+AC_DEFUN([gl_STDLIB_H_DEFAULTS],
+[
+ GNULIB_MALLOC_POSIX=0; AC_SUBST([GNULIB_MALLOC_POSIX])
+ GNULIB_REALLOC_POSIX=0; AC_SUBST([GNULIB_REALLOC_POSIX])
+ GNULIB_CALLOC_POSIX=0; AC_SUBST([GNULIB_CALLOC_POSIX])
+ GNULIB_GETSUBOPT=0; AC_SUBST([GNULIB_GETSUBOPT])
+ GNULIB_MKDTEMP=0; AC_SUBST([GNULIB_MKDTEMP])
+ GNULIB_MKSTEMP=0; AC_SUBST([GNULIB_MKSTEMP])
+ dnl Assume proper GNU behavior unless another module says otherwise.
+ HAVE_CALLOC_POSIX=1; AC_SUBST([HAVE_CALLOC_POSIX])
+ HAVE_GETSUBOPT=1; AC_SUBST([HAVE_GETSUBOPT])
+ HAVE_MALLOC_POSIX=1; AC_SUBST([HAVE_MALLOC_POSIX])
+ HAVE_MKDTEMP=1; AC_SUBST([HAVE_MKDTEMP])
+ HAVE_REALLOC_POSIX=1; AC_SUBST([HAVE_REALLOC_POSIX])
+ REPLACE_MKSTEMP=0; AC_SUBST([REPLACE_MKSTEMP])
+])
diff --git a/lgl/m4/time_h.m4 b/lgl/m4/time_h.m4
index 3f543a15a7..d42a635ece 100644
--- a/lgl/m4/time_h.m4
+++ b/lgl/m4/time_h.m4
@@ -65,7 +65,7 @@ AC_DEFUN([gl_CHECK_TYPE_STRUCT_TIMESPEC],
[[static struct timespec x; x.tv_sec = x.tv_nsec;]])],
[gl_cv_sys_struct_timespec_in_sys_time_h=yes],
[gl_cv_sys_struct_timespec_in_sys_time_h=no])])
- if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
+ if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
fi
fi
diff --git a/lgl/realloc.c b/lgl/realloc.c
new file mode 100644
index 0000000000..bcb6969ec5
--- /dev/null
+++ b/lgl/realloc.c
@@ -0,0 +1,65 @@
+/* realloc() function that is glibc compatible.
+
+ Copyright (C) 1997, 2003, 2004, 2006, 2007 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
+ the Free Software Foundation; either version 2.1, 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 Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser 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. */
+
+/* written by Jim Meyering and Bruno Haible */
+
+#include <config.h>
+/* Only the AC_FUNC_REALLOC macro defines 'realloc' already in config.h. */
+#ifdef realloc
+# define NEED_REALLOC_GNU
+# undef realloc
+#endif
+
+/* Specification. */
+#include <stdlib.h>
+
+#include <errno.h>
+
+/* Call the system's malloc and realloc below. */
+#undef malloc
+#undef realloc
+
+/* Change the size of an allocated block of memory P to N bytes,
+ with error checking. If N is zero, change it to 1. If P is NULL,
+ use malloc. */
+
+void *
+rpl_realloc (void *p, size_t n)
+{
+ void *result;
+
+#ifdef NEED_REALLOC_GNU
+ if (n == 0)
+ {
+ n = 1;
+
+ /* In theory realloc might fail, so don't rely on it to free. */
+ free (p);
+ p = NULL;
+ }
+#endif
+
+ result = (p == NULL ? malloc (n) : realloc (p, n));
+
+#if !HAVE_REALLOC_POSIX
+ if (result == NULL)
+ errno = ENOMEM;
+#endif
+
+ return result;
+}
diff --git a/lgl/stdlib_.h b/lgl/stdlib_.h
new file mode 100644
index 0000000000..9ca200bcef
--- /dev/null
+++ b/lgl/stdlib_.h
@@ -0,0 +1,177 @@
+/* A GNU-like <stdlib.h>.
+
+ Copyright (C) 1995, 2001-2002, 2006-2007 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
+ the Free Software Foundation; either version 2.1, 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 Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser 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. */
+
+#if defined __need_malloc_and_calloc
+/* Special invocation convention inside glibc header files. */
+
+#@INCLUDE_NEXT@ @NEXT_STDLIB_H@
+
+#else
+/* Normal invocation convention. */
+
+#ifndef _GL_STDLIB_H
+
+/* The include_next requires a split double-inclusion guard. */
+#@INCLUDE_NEXT@ @NEXT_STDLIB_H@
+
+#ifndef _GL_STDLIB_H
+#define _GL_STDLIB_H
+
+
+/* The definition of GL_LINK_WARNING is copied here. */
+
+
+/* Some systems do not define EXIT_*, despite otherwise supporting C89. */
+#ifndef EXIT_SUCCESS
+# define EXIT_SUCCESS 0
+#endif
+/* Tandem/NSK and other platforms that define EXIT_FAILURE as -1 interfere
+ with proper operation of xargs. */
+#ifndef EXIT_FAILURE
+# define EXIT_FAILURE 1
+#elif EXIT_FAILURE != 1
+# undef EXIT_FAILURE
+# define EXIT_FAILURE 1
+#endif
+
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+
+#if @GNULIB_MALLOC_POSIX@
+# if !@HAVE_MALLOC_POSIX@
+# undef malloc
+# define malloc rpl_malloc
+extern void * malloc (size_t size);
+# endif
+#elif defined GNULIB_POSIXCHECK
+# undef malloc
+# define malloc(s) \
+ (GL_LINK_WARNING ("malloc is not POSIX compliant everywhere - " \
+ "use gnulib module malloc-posix for portability"), \
+ malloc (s))
+#endif
+
+
+#if @GNULIB_REALLOC_POSIX@
+# if !@HAVE_REALLOC_POSIX@
+# undef realloc
+# define realloc rpl_realloc
+extern void * realloc (void *ptr, size_t size);
+# endif
+#elif defined GNULIB_POSIXCHECK
+# undef realloc
+# define realloc(p,s) \
+ (GL_LINK_WARNING ("realloc is not POSIX compliant everywhere - " \
+ "use gnulib module realloc-posix for portability"), \
+ realloc (p, s))
+#endif
+
+
+#if @GNULIB_CALLOC_POSIX@
+# if !@HAVE_CALLOC_POSIX@
+# undef calloc
+# define calloc rpl_calloc
+extern void * calloc (size_t nmemb, size_t size);
+# endif
+#elif defined GNULIB_POSIXCHECK
+# undef calloc
+# define calloc(n,s) \
+ (GL_LINK_WARNING ("calloc is not POSIX compliant everywhere - " \
+ "use gnulib module calloc-posix for portability"), \
+ calloc (n, s))
+#endif
+
+
+#if @GNULIB_GETSUBOPT@
+/* Assuming *OPTIONP is a comma separated list of elements of the form
+ "token" or "token=value", getsubopt parses the first of these elements.
+ If the first element refers to a "token" that is member of the given
+ NULL-terminated array of tokens:
+ - It replaces the comma with a NUL byte, updates *OPTIONP to point past
+ the first option and the comma, sets *VALUEP to the value of the
+ element (or NULL if it doesn't contain an "=" sign),
+ - It returns the index of the "token" in the given array of tokens.
+ Otherwise it returns -1, and *OPTIONP and *VALUEP are undefined.
+ For more details see the POSIX:2001 specification.
+ http://www.opengroup.org/susv3xsh/getsubopt.html */
+# if !@HAVE_GETSUBOPT@
+extern int getsubopt (char **optionp, char *const *tokens, char **valuep);
+# endif
+#elif defined GNULIB_POSIXCHECK
+# undef getsubopt
+# define getsubopt(o,t,v) \
+ (GL_LINK_WARNING ("getsubopt is unportable - " \
+ "use gnulib module getsubopt for portability"), \
+ getsubopt (o, t, v))
+#endif
+
+
+#if @GNULIB_MKDTEMP@
+# if !@HAVE_MKDTEMP@
+/* Create a unique temporary directory from TEMPLATE.
+ The last six characters of TEMPLATE must be "XXXXXX";
+ they are replaced with a string that makes the directory name unique.
+ Returns TEMPLATE, or a null pointer if it cannot get a unique name.
+ The directory is created mode 700. */
+extern char * mkdtemp (char * /*template*/);
+# endif
+#elif defined GNULIB_POSIXCHECK
+# undef mkdtemp
+# define mkdtemp(t) \
+ (GL_LINK_WARNING ("mkdtemp is unportable - " \
+ "use gnulib module mkdtemp for portability"), \
+ mkdtemp (t))
+#endif
+
+
+#if @GNULIB_MKSTEMP@
+# if @REPLACE_MKSTEMP@
+/* Create a unique temporary file from TEMPLATE.
+ The last six characters of TEMPLATE must be "XXXXXX";
+ they are replaced with a string that makes the file name unique.
+ The file is then created, ensuring it didn't exist before.
+ The file is created read-write (mask at least 0600 & ~umask), but it may be
+ world-readable and world-writable (mask 0666 & ~umask), depending on the
+ implementation.
+ Returns the open file descriptor if successful, otherwise -1 and errno
+ set. */
+# define mkstemp rpl_mkstemp
+extern int mkstemp (char * /*template*/);
+# else
+/* On MacOS X 10.3, only <unistd.h> declares mkstemp. */
+# include <unistd.h>
+# endif
+#elif defined GNULIB_POSIXCHECK
+# undef mkstemp
+# define mkstemp(t) \
+ (GL_LINK_WARNING ("mkstemp is unportable - " \
+ "use gnulib module mkstemp for portability"), \
+ mkstemp (t))
+#endif
+
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* _GL_STDLIB_H */
+#endif /* _GL_STDLIB_H */
+#endif
diff --git a/lib/.cvsignore b/lib/.cvsignore
deleted file mode 100644
index aecf4df2dd..0000000000
--- a/lib/.cvsignore
+++ /dev/null
@@ -1,21 +0,0 @@
-.deps
-.libs
-*.lo
-*.o
-*.la
-Makefile.in
-gnutls.h.in
-Makefile
-.cvsignore
-*.da
-*.gcov
-*.bb
-*.bbg
-libgnutls-config
-gnutls.h
-x509_ASN.c
-*.tex
-*.texi
-t-openpgp.c
-autogen.sh
-gnutls.pc
diff --git a/lib/gnutls_algorithms.c b/lib/gnutls_algorithms.c
index 95463bfbcc..7ec696e253 100644
--- a/lib/gnutls_algorithms.c
+++ b/lib/gnutls_algorithms.c
@@ -392,20 +392,19 @@ typedef struct
/* SRP (not in TLS 1.0)
- * draft-ietf-tls-srp-02:
+ * draft-ietf-tls-srp-14:
*/
-#define GNUTLS_SRP_SHA_3DES_EDE_CBC_SHA1 { 0x00, 0x50 }
-#define GNUTLS_SRP_SHA_AES_128_CBC_SHA1 { 0x00, 0x53 }
-#define GNUTLS_SRP_SHA_AES_256_CBC_SHA1 { 0x00, 0x56 }
+#define GNUTLS_SRP_SHA_3DES_EDE_CBC_SHA1 { 0xC0, 0x1A }
+#define GNUTLS_SRP_SHA_RSA_3DES_EDE_CBC_SHA1 { 0xC0, 0x1B }
+#define GNUTLS_SRP_SHA_DSS_3DES_EDE_CBC_SHA1 { 0xC0, 0x1C }
-#define GNUTLS_SRP_SHA_RSA_3DES_EDE_CBC_SHA1 { 0x00, 0x51 }
-#define GNUTLS_SRP_SHA_DSS_3DES_EDE_CBC_SHA1 { 0x00, 0x52 }
+#define GNUTLS_SRP_SHA_AES_128_CBC_SHA1 { 0xC0, 0x1D }
+#define GNUTLS_SRP_SHA_RSA_AES_128_CBC_SHA1 { 0xC0, 0x1E }
+#define GNUTLS_SRP_SHA_DSS_AES_128_CBC_SHA1 { 0xC0, 0x1F }
-#define GNUTLS_SRP_SHA_RSA_AES_128_CBC_SHA1 { 0x00, 0x54 }
-#define GNUTLS_SRP_SHA_DSS_AES_128_CBC_SHA1 { 0x00, 0x55 }
-
-#define GNUTLS_SRP_SHA_RSA_AES_256_CBC_SHA1 { 0x00, 0x57 }
-#define GNUTLS_SRP_SHA_DSS_AES_256_CBC_SHA1 { 0x00, 0x58 }
+#define GNUTLS_SRP_SHA_AES_256_CBC_SHA1 { 0xC0, 0x20 }
+#define GNUTLS_SRP_SHA_RSA_AES_256_CBC_SHA1 { 0xC0, 0x21 }
+#define GNUTLS_SRP_SHA_DSS_AES_256_CBC_SHA1 { 0xC0, 0x22 }
/* RSA
*/
diff --git a/lib/gnutls_int.h b/lib/gnutls_int.h
index 6f01c96afb..3e6ef39575 100644
--- a/lib/gnutls_int.h
+++ b/lib/gnutls_int.h
@@ -144,7 +144,7 @@ typedef enum extensions_t
GNUTLS_EXTENSION_AUTHZ_CLIENT = 7,
GNUTLS_EXTENSION_AUTHZ_SERVER = 8,
GNUTLS_EXTENSION_CERT_TYPE = 9,
- GNUTLS_EXTENSION_SRP = 26,
+ GNUTLS_EXTENSION_SRP = 12,
GNUTLS_EXTENSION_INNER_APPLICATION = 37703
} extensions_t;
diff --git a/lib/minitasn1/.cvsignore b/lib/minitasn1/.cvsignore
deleted file mode 100644
index eebab86ac7..0000000000
--- a/lib/minitasn1/.cvsignore
+++ /dev/null
@@ -1,7 +0,0 @@
-.deps
-.libs
-*.lo
-*.o
-Makefile.in
-Makefile
-*.la
diff --git a/lib/x509/.cvsignore b/lib/x509/.cvsignore
deleted file mode 100644
index db35c56494..0000000000
--- a/lib/x509/.cvsignore
+++ /dev/null
@@ -1,15 +0,0 @@
-.deps
-.libs
-*.lo
-*.o
-*.la
-Makefile.in
-gnutls.h.in
-Makefile
-.cvsignore
-*.da
-*.gcov
-*.bb
-*.bbg
-*.tex
-*.texi
diff --git a/libextra/.cvsignore b/libextra/.cvsignore
deleted file mode 100644
index df7b3f7b8c..0000000000
--- a/libextra/.cvsignore
+++ /dev/null
@@ -1,12 +0,0 @@
-.deps
-.libs
-Makefile
-Makefile.in
-gnutls-extra-api.tex
-gnutls-extra-api.texi
-libgnutls-extra-config
-libgnutls-extra.la
-libgnutls-openssl.la
-*.lo
-gnutls-extra.pc
-ia-api.texi
diff --git a/libextra/minilzo/.cvsignore b/libextra/minilzo/.cvsignore
deleted file mode 100644
index ff0e08dd20..0000000000
--- a/libextra/minilzo/.cvsignore
+++ /dev/null
@@ -1,7 +0,0 @@
-.deps
-.libs
-Makefile
-Makefile.in
-libminilzo.la
-minilzo.lo
-testmini
diff --git a/libextra/opencdk/.cvsignore b/libextra/opencdk/.cvsignore
deleted file mode 100644
index 637c8ecd6d..0000000000
--- a/libextra/opencdk/.cvsignore
+++ /dev/null
@@ -1,6 +0,0 @@
-.deps
-.libs
-Makefile
-Makefile.in
-libminiopencdk.la
-*.lo
diff --git a/libextra/openpgp/.cvsignore b/libextra/openpgp/.cvsignore
deleted file mode 100644
index c6574ee18a..0000000000
--- a/libextra/openpgp/.cvsignore
+++ /dev/null
@@ -1,11 +0,0 @@
-.deps
-.libs
-*.lo
-*.o
-*.la
-Makefile.in
-gnutls.h.in
-Makefile
-.cvsignore
-pgp-api.tex
-pgp-api.texi
diff --git a/m4/.cvsignore b/m4/.cvsignore
deleted file mode 100644
index 6b11e33215..0000000000
--- a/m4/.cvsignore
+++ /dev/null
@@ -1,33 +0,0 @@
-codeset.m4
-gettext.m4
-glibc2.m4
-glibc21.m4
-iconv.m4
-intdiv0.m4
-intmax.m4
-inttypes-pri.m4
-inttypes.m4
-inttypes_h.m4
-isc-posix.m4
-lcmessage.m4
-lib-ld.m4
-lib-link.m4
-lib-prefix.m4
-longdouble.m4
-longlong.m4
-nls.m4
-po.m4
-printf-posix.m4
-progtest.m4
-signed.m4
-size_max.m4
-stdint_h.m4
-uintmax_t.m4
-ulonglong.m4
-wchar_t.m4
-wint_t.m4
-xsize.m4
-intl.m4
-intldir.m4
-lock.m4
-visibility.m4
diff --git a/po/.cvsignore b/po/.cvsignore
deleted file mode 100644
index fb900c8b10..0000000000
--- a/po/.cvsignore
+++ /dev/null
@@ -1,20 +0,0 @@
-Makefile
-Makefile.in
-Makefile.in.in
-Makevars.template
-POTFILES
-Rules-quot
-boldquot.sed
-en@boldquot.header
-en@boldquot.insert-header
-en@boldquot.po
-en@quot.header
-en@quot.insert-header
-en@quot.po
-insert-header.sin
-gnutls.pot
-quot.sed
-remove-potcdate.sin
-remove-potcdate.sed
-stamp-po
-*.gmo
diff --git a/src/.cvsignore b/src/.cvsignore
deleted file mode 100644
index 2297a9df00..0000000000
--- a/src/.cvsignore
+++ /dev/null
@@ -1,21 +0,0 @@
-.cvsignore
-cli
-serv
-prime
-gnutls-rsm.db
-Makefile
-Makefile.in
-.deps
-.libs
-srpcrypt
-asn1c
-CertificateExample
-CrlExample
-certtool
-gnutls-cli
-gnutls-cli-debug
-gnutls-serv
-retcodes
-errcodes
-srptool
-psktool
diff --git a/src/cfg/.cvsignore b/src/cfg/.cvsignore
deleted file mode 100644
index 282522db03..0000000000
--- a/src/cfg/.cvsignore
+++ /dev/null
@@ -1,2 +0,0 @@
-Makefile
-Makefile.in
diff --git a/src/cfg/platon/.cvsignore b/src/cfg/platon/.cvsignore
deleted file mode 100644
index 282522db03..0000000000
--- a/src/cfg/platon/.cvsignore
+++ /dev/null
@@ -1,2 +0,0 @@
-Makefile
-Makefile.in
diff --git a/src/cfg/platon/str/.cvsignore b/src/cfg/platon/str/.cvsignore
deleted file mode 100644
index 282522db03..0000000000
--- a/src/cfg/platon/str/.cvsignore
+++ /dev/null
@@ -1,2 +0,0 @@
-Makefile
-Makefile.in
diff --git a/src/openpgp/.cvsignore b/src/openpgp/.cvsignore
deleted file mode 100644
index 282522db03..0000000000
--- a/src/openpgp/.cvsignore
+++ /dev/null
@@ -1,2 +0,0 @@
-Makefile
-Makefile.in
diff --git a/src/srp/.cvsignore b/src/srp/.cvsignore
deleted file mode 100644
index 02b0523973..0000000000
--- a/src/srp/.cvsignore
+++ /dev/null
@@ -1,4 +0,0 @@
-Makefile
-Makefile.in
-.deps
-.libs
diff --git a/src/x509/.cvsignore b/src/x509/.cvsignore
deleted file mode 100644
index 02b0523973..0000000000
--- a/src/x509/.cvsignore
+++ /dev/null
@@ -1,4 +0,0 @@
-Makefile
-Makefile.in
-.deps
-.libs
diff --git a/tests/.cvsignore b/tests/.cvsignore
deleted file mode 100644
index f0e98e0b43..0000000000
--- a/tests/.cvsignore
+++ /dev/null
@@ -1,18 +0,0 @@
-.deps
-.libs
-Makefile
-Makefile.in
-anonself
-simple
-*.lo
-*.la
-certder
-dhepskself
-gc
-openssl
-pskself
-resume
-set_pkcs12_cred
-tlsia
-certificate_set_x509_crl
-dn
diff --git a/tests/hostname-check/.cvsignore b/tests/hostname-check/.cvsignore
deleted file mode 100644
index b7d75595dd..0000000000
--- a/tests/hostname-check/.cvsignore
+++ /dev/null
@@ -1,5 +0,0 @@
-.deps
-.libs
-Makefile
-Makefile.in
-hostname-check
diff --git a/tests/key-id/.cvsignore b/tests/key-id/.cvsignore
deleted file mode 100644
index 282522db03..0000000000
--- a/tests/key-id/.cvsignore
+++ /dev/null
@@ -1,2 +0,0 @@
-Makefile
-Makefile.in
diff --git a/tests/nist-pkits/.cvsignore b/tests/nist-pkits/.cvsignore
deleted file mode 100644
index e83bc66954..0000000000
--- a/tests/nist-pkits/.cvsignore
+++ /dev/null
@@ -1,10 +0,0 @@
-ReadMe.txt
-certpairs
-certs
-crls
-pkcs12
-pkits.ldif
-pkits.schema
-smime
-pkits_test_list_generator
-out.txt
diff --git a/tests/pathlen/.cvsignore b/tests/pathlen/.cvsignore
deleted file mode 100644
index 282522db03..0000000000
--- a/tests/pathlen/.cvsignore
+++ /dev/null
@@ -1,2 +0,0 @@
-Makefile
-Makefile.in
diff --git a/tests/pkcs1-padding/.cvsignore b/tests/pkcs1-padding/.cvsignore
deleted file mode 100644
index 282522db03..0000000000
--- a/tests/pkcs1-padding/.cvsignore
+++ /dev/null
@@ -1,2 +0,0 @@
-Makefile
-Makefile.in
diff --git a/tests/pkcs12-decode/.cvsignore b/tests/pkcs12-decode/.cvsignore
deleted file mode 100644
index 282522db03..0000000000
--- a/tests/pkcs12-decode/.cvsignore
+++ /dev/null
@@ -1,2 +0,0 @@
-Makefile
-Makefile.in
diff --git a/tests/pkcs8-decode/.cvsignore b/tests/pkcs8-decode/.cvsignore
deleted file mode 100644
index 282522db03..0000000000
--- a/tests/pkcs8-decode/.cvsignore
+++ /dev/null
@@ -1,2 +0,0 @@
-Makefile
-Makefile.in
diff --git a/tests/rsa-md5-collision/.cvsignore b/tests/rsa-md5-collision/.cvsignore
deleted file mode 100644
index 282522db03..0000000000
--- a/tests/rsa-md5-collision/.cvsignore
+++ /dev/null
@@ -1,2 +0,0 @@
-Makefile
-Makefile.in
diff --git a/tests/sha2/.cvsignore b/tests/sha2/.cvsignore
deleted file mode 100644
index 282522db03..0000000000
--- a/tests/sha2/.cvsignore
+++ /dev/null
@@ -1,2 +0,0 @@
-Makefile
-Makefile.in
diff --git a/tests/userid/.cvsignore b/tests/userid/.cvsignore
deleted file mode 100644
index 282522db03..0000000000
--- a/tests/userid/.cvsignore
+++ /dev/null
@@ -1,2 +0,0 @@
-Makefile
-Makefile.in
diff --git a/tests/x509paths/.cvsignore b/tests/x509paths/.cvsignore
deleted file mode 100644
index 33d7cd8449..0000000000
--- a/tests/x509paths/.cvsignore
+++ /dev/null
@@ -1,2 +0,0 @@
-X509tests
-chain*.pem