[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
assume <wchar.h>
From: |
Eric Blake |
Subject: |
assume <wchar.h> |
Date: |
Tue, 16 Jan 2007 07:30:08 -0700 |
User-agent: |
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.0.9) Gecko/20061207 Thunderbird/1.5.0.9 Mnenhy/0.7.4.666 |
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
OK to apply this patch, which makes several modules depend on the recently
added wchar module?
2007-01-16 Eric Blake <address@hidden>
* modules/fnmatch (Depends-on): Depend on wchar.
* lib/fnmatch.c (WIDE_CHAR_SUPPORT): Assume <wchar.h>.
* modules/mbswidth (Depends-on): Depend on wchar.
* lib/mbswidth.c: Assume <wchar.h>.
* modules/quotearg (Depends-on): Depend on wchar.
* lib/quotearg.c: Assume <wchar.h>.
* modules/regex (Depends-on): Depend on wchar.
* lib/regex_internal.h: Assume <wchar.h>.
* modules/stdint (Depends-on): Depend on wchar.
* lib/stdint_.h [!defined WCHAR_MIN]: Assume <wchar.h>.
- --
Don't work too hard, make some time for fun as well!
Eric Blake address@hidden
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFFrOFv84KuGfSFAYARAvZHAJ0UbBu5S5mUim/60kzBQJ2I/jRfAgCguzVf
rndNqtvh7Knvxh6ZNEVAyVQ=
=z7ti
-----END PGP SIGNATURE-----
Index: lib/fnmatch.c
===================================================================
RCS file: /sources/gnulib/gnulib/lib/fnmatch.c,v
retrieving revision 1.39
diff -u -p -r1.39 fnmatch.c
--- lib/fnmatch.c 27 Dec 2006 13:19:04 -0000 1.39
+++ lib/fnmatch.c 16 Jan 2007 14:28:23 -0000
@@ -1,4 +1,4 @@
-/* Copyright (C)
1991,1992,1993,1996,1997,1998,1999,2000,2001,2002,2003,2004,2005,2006
+/* Copyright (C)
1991,1992,1993,1996,1997,1998,1999,2000,2001,2002,2003,2004,2005,2006,2007
Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
@@ -40,7 +40,7 @@
#include <string.h>
#define WIDE_CHAR_SUPPORT \
- (HAVE_WCTYPE_H && HAVE_WCHAR_H && HAVE_BTOWC && HAVE_ISWCTYPE \
+ (HAVE_WCTYPE_H && HAVE_BTOWC && HAVE_ISWCTYPE \
&& HAVE_WMEMCHR && (HAVE_WMEMCPY || HAVE_WMEMPCPY))
/* For platform which support the ISO C amendement 1 functionality we
Index: lib/mbswidth.c
===================================================================
RCS file: /sources/gnulib/gnulib/lib/mbswidth.c,v
retrieving revision 1.20
diff -u -p -r1.20 mbswidth.c
--- lib/mbswidth.c 27 Dec 2006 19:54:25 -0000 1.20
+++ lib/mbswidth.c 16 Jan 2007 14:28:23 -0000
@@ -1,5 +1,5 @@
/* Determine the number of screen columns needed for a string.
- Copyright (C) 2000-2006 Free Software Foundation, Inc.
+ Copyright (C) 2000-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
@@ -31,15 +31,7 @@
#include <ctype.h>
/* Get mbstate_t, mbrtowc(), mbsinit(). */
-#if HAVE_WCHAR_H
-/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
- <wchar.h>.
- BSD/OS 4.1 has a bug: <stdio.h> and <time.h> must be included before
- <wchar.h>. */
-# include <stdio.h>
-# include <time.h>
-# include <wchar.h>
-#endif
+#include <wchar.h>
/* Get wcwidth(). */
#include "wcwidth.h"
Index: lib/quotearg.c
===================================================================
RCS file: /sources/gnulib/gnulib/lib/quotearg.c,v
retrieving revision 1.53
diff -u -p -r1.53 quotearg.c
--- lib/quotearg.c 22 Dec 2006 00:21:54 -0000 1.53
+++ lib/quotearg.c 16 Jan 2007 14:28:23 -0000
@@ -1,6 +1,6 @@
/* quotearg.c - quote arguments for output
- Copyright (C) 1998, 1999, 2000, 2001, 2002, 2004, 2005, 2006 Free
+ Copyright (C) 1998, 1999, 2000, 2001, 2002, 2004, 2005, 2006, 2007 Free
Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
@@ -31,20 +31,12 @@
#include <stdbool.h>
#include <stdlib.h>
#include <string.h>
+#include <wchar.h>
#include "gettext.h"
#define _(msgid) gettext (msgid)
#define N_(msgid) msgid
-#if HAVE_WCHAR_H
-
-/* BSD/OS 4.1 wchar.h requires FILE and struct tm to be declared. */
-# include <stdio.h>
-# include <time.h>
-
-# include <wchar.h>
-#endif
-
#if !HAVE_MBRTOWC
/* Disable multibyte processing entirely. Since MB_CUR_MAX is 1, the
other macros are defined only for documentation and to satisfy C
Index: lib/regex_internal.h
===================================================================
RCS file: /sources/gnulib/gnulib/lib/regex_internal.h,v
retrieving revision 1.27
diff -u -p -r1.27 regex_internal.h
--- lib/regex_internal.h 22 Dec 2006 00:21:54 -0000 1.27
+++ lib/regex_internal.h 16 Jan 2007 14:28:23 -0000
@@ -1,5 +1,5 @@
/* Extended regular expression matching and search library.
- Copyright (C) 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
+ Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation,
Inc.
This file is part of the GNU C Library.
Contributed by Isamu Hasegawa <address@hidden>.
@@ -37,9 +37,8 @@
#if defined HAVE_LOCALE_H || defined _LIBC
# include <locale.h>
#endif
-#if defined HAVE_WCHAR_H || defined _LIBC
-# include <wchar.h>
-#endif /* HAVE_WCHAR_H || _LIBC */
+
+#include <wchar.h>
#include <wctype.h>
#include <stdint.h>
#if defined _LIBC
@@ -87,7 +86,7 @@
# define SIZE_MAX ((size_t) -1)
#endif
-#if (defined MB_CUR_MAX && HAVE_LOCALE_H && HAVE_WCTYPE_H && HAVE_WCHAR_H &&
HAVE_ISWCTYPE && HAVE_WCRTOMB && HAVE_MBRTOWC && HAVE_WCSCOLL) || _LIBC
+#if (defined MB_CUR_MAX && HAVE_LOCALE_H && HAVE_WCTYPE_H && HAVE_ISWCTYPE &&
HAVE_WCRTOMB && HAVE_MBRTOWC && HAVE_WCSCOLL) || _LIBC
# define RE_ENABLE_I18N
#endif
Index: lib/stdint_.h
===================================================================
RCS file: /sources/gnulib/gnulib/lib/stdint_.h,v
retrieving revision 1.36
diff -u -p -r1.36 stdint_.h
--- lib/stdint_.h 10 Nov 2006 01:03:39 -0000 1.36
+++ lib/stdint_.h 16 Jan 2007 14:28:23 -0000
@@ -1,4 +1,4 @@
-/* Copyright (C) 2001-2002, 2004-2006 Free Software Foundation, Inc.
+/* Copyright (C) 2001-2002, 2004-2007 Free Software Foundation, Inc.
Written by Paul Eggert, Bruno Haible, Sam Steingold, Peter Burwood.
This file is part of gnulib.
@@ -82,11 +82,7 @@
#if ! defined __cplusplus || defined __STDC_CONSTANT_MACROS
/* Get WCHAR_MIN, WCHAR_MAX. */
-# if @HAVE_WCHAR_H@ && ! (defined WCHAR_MIN && defined WCHAR_MAX)
- /* BSD/OS 4.1 has a bug: <stdio.h> and <time.h> must be included before
- <wchar.h>. */
-# include <stdio.h>
-# include <time.h>
+# if ! (defined WCHAR_MIN && defined WCHAR_MAX)
# include <wchar.h>
# endif
Index: modules/fnmatch
===================================================================
RCS file: /sources/gnulib/gnulib/modules/fnmatch,v
retrieving revision 1.16
diff -u -p -r1.16 fnmatch
--- modules/fnmatch 22 Dec 2006 00:21:54 -0000 1.16
+++ modules/fnmatch 16 Jan 2007 14:28:25 -0000
@@ -11,6 +11,7 @@ m4/fnmatch.m4
Depends-on:
alloca
stdbool
+wchar
wctype
configure.ac:
Index: modules/mbswidth
===================================================================
RCS file: /sources/gnulib/gnulib/modules/mbswidth,v
retrieving revision 1.6
diff -u -p -r1.6 mbswidth
--- modules/mbswidth 27 Dec 2006 19:54:25 -0000 1.6
+++ modules/mbswidth 16 Jan 2007 14:28:25 -0000
@@ -9,6 +9,7 @@ m4/mbrtowc.m4
m4/mbswidth.m4
Depends-on:
+wchar
wctype
wcwidth
Index: modules/quotearg
===================================================================
RCS file: /sources/gnulib/gnulib/modules/quotearg,v
retrieving revision 1.11
diff -u -p -r1.11 quotearg
--- modules/quotearg 22 Dec 2006 00:21:54 -0000 1.11
+++ modules/quotearg 16 Jan 2007 14:28:25 -0000
@@ -9,10 +9,11 @@ m4/mbrtowc.m4
m4/quotearg.m4
Depends-on:
-xalloc
gettext-h
stdbool
+wchar
wctype
+xalloc
configure.ac:
gl_QUOTEARG
Index: modules/regex
===================================================================
RCS file: /sources/gnulib/gnulib/modules/regex,v
retrieving revision 1.19
diff -u -p -r1.19 regex
--- modules/regex 22 Dec 2006 00:21:54 -0000 1.19
+++ modules/regex 16 Jan 2007 14:28:25 -0000
@@ -19,6 +19,7 @@ malloc
stdint
strcase
ssize_t
+wchar
wctype
configure.ac:
Index: modules/stdint
===================================================================
RCS file: /sources/gnulib/gnulib/modules/stdint,v
retrieving revision 1.18
diff -u -p -r1.18 stdint
--- modules/stdint 26 Dec 2006 18:42:09 -0000 1.18
+++ modules/stdint 16 Jan 2007 14:28:25 -0000
@@ -14,6 +14,7 @@ m4/ulonglong.m4
Depends-on:
absolute-header
+wchar
configure.ac:
gl_STDINT_H
@@ -26,8 +27,7 @@ BUILT_SOURCES += $(STDINT_H)
stdint.h: stdint_.h
rm -f address@hidden $@
{ echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \
- sed -e 's/@''HAVE_WCHAR_H''@/$(HAVE_WCHAR_H)/g' \
- -e 's/@''HAVE_STDINT_H''@/$(HAVE_STDINT_H)/g' \
+ sed -e 's/@''HAVE_STDINT_H''@/$(HAVE_STDINT_H)/g' \
-e 's|@''ABSOLUTE_STDINT_H''@|$(ABSOLUTE_STDINT_H)|g' \
-e 's/@''HAVE_SYS_TYPES_H''@/$(HAVE_SYS_TYPES_H)/g' \
-e 's/@''HAVE_INTTYPES_H''@/$(HAVE_INTTYPES_H)/g' \
- assume <wchar.h>,
Eric Blake <=