From: Eric Blake Date: Mon, 29 Dec 2008 16:09:58 +0000 (-0700) Subject: wchar.h: supply WEOF on Irix 5.3 X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3cb753d3f0109c172d5c5e9c595b287b034bd577;p=pspp wchar.h: supply WEOF on Irix 5.3 * lib/wchar.in.h (wint_t): Also supply WEOF. * lib/wctype.in.h (wint_t): Likewise. * doc/posix-headers/wchar.texi (wchar.h): Document the bug. * doc/posix-headers/wctype.texi (wctype.h): Likewise. Reported by Tom G. Christensen. Signed-off-by: Eric Blake --- diff --git a/ChangeLog b/ChangeLog index 4936022afb..8bd92e7c09 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,12 @@ +2008-12-29 Eric Blake + + wchar.h: supply WEOF on Irix 5.3 + * lib/wchar.in.h (wint_t): Also supply WEOF. + * lib/wctype.in.h (wint_t): Likewise. + * doc/posix-headers/wchar.texi (wchar.h): Document the bug. + * doc/posix-headers/wctype.texi (wctype.h): Likewise. + Reported by Tom G. Christensen. + 2008-12-26 Bruno Haible * m4/multiarch.m4 (gl_MULTIARCH): Recognize also the architecture names @@ -148,9 +157,9 @@ * doc/glibc-functions/wmempcpy.texi: Likewise. 2008-12-22 Ingo Weinhold (tiny change) - Eric Blake - Paolo Bonzini - Bruno Haible + Eric Blake + Paolo Bonzini + Bruno Haible Make c-stack work on Haiku. * lib/c-stack.c (SA_ONSTACK): Define fallback. diff --git a/doc/posix-headers/wchar.texi b/doc/posix-headers/wchar.texi index 5e121e8286..bdd8232d4c 100644 --- a/doc/posix-headers/wchar.texi +++ b/doc/posix-headers/wchar.texi @@ -14,7 +14,7 @@ Linux uClibc built without wide character support. This header file is not self-contained on some platforms: OSF/1 with Desktop Toolkit C, BSD/OS 4.0.1. @item -The type @code{wint_t} is missing on some platforms: +The type @code{wint_t} and macro @code{WEOF} are missing on some platforms: IRIX 5.3. @end itemize diff --git a/doc/posix-headers/wctype.texi b/doc/posix-headers/wctype.texi index ff56cbaeb9..d3438e48b6 100644 --- a/doc/posix-headers/wctype.texi +++ b/doc/posix-headers/wctype.texi @@ -14,7 +14,7 @@ HP-UX 11.00, BeOS. This header file is not self-contained on some platforms: Solaris 2.5, OSF/1 with Desktop Toolkit C, BSD/OS 4.0.1. @item -The type @code{wint_t} is missing on some platforms: +The type @code{wint_t} and macro @code{WEOF} are missing on some platforms: IRIX 5.3. @item The functions @code{isw*} are missing on some platforms: diff --git a/lib/wchar.in.h b/lib/wchar.in.h index 1250d3b975..74e5f249a1 100644 --- a/lib/wchar.in.h +++ b/lib/wchar.in.h @@ -68,6 +68,9 @@ extern "C" { /* Define wint_t. (Also done in wctype.in.h.) */ #if !@HAVE_WINT_T@ && !defined wint_t # define wint_t int +# ifndef WEOF +# define WEOF -1 +# endif #endif diff --git a/lib/wctype.in.h b/lib/wctype.in.h index 8b33d7134f..bcd0151d2f 100644 --- a/lib/wctype.in.h +++ b/lib/wctype.in.h @@ -57,6 +57,9 @@ /* Define wint_t. (Also done in wchar.in.h.) */ #if !@HAVE_WINT_T@ && !defined wint_t # define wint_t int +# ifndef WEOF +# define WEOF -1 +# endif #endif /* FreeBSD 4.4 to 4.11 has but lacks the functions.