Mercurial > hg > octave-shane > gnulib-hg
annotate m4/wchar_h.m4 @ 14290:0da9f0fe36fe
New module 'wcsncmp'.
* modules/wcsncmp: New file.
* lib/wchar.in.h (wcsncmp): New declaration.
* lib/wcsncmp.c: New file.
* lib/wcsncmp-impl.h: New file, from libutf8 with modifications.
* m4/wcsncmp.m4: New file.
* m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcsncmp is declared.
(gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSNCMP, HAVE_WCSNCMP.
* modules/wchar (Makefile.am): Substitute GNULIB_WCSNCMP, HAVE_WCSNCMP.
* tests/test-wchar-c++.cc: Test the declaration of wcsncmp.
* doc/posix-functions/wcsncmp.texi: Mention the new module.
author | Bruno Haible <bruno@clisp.org> |
---|---|
date | Sun, 06 Feb 2011 04:47:49 +0100 |
parents | b5843d4d8441 |
children | 517e0af1a79b |
rev | line source |
---|---|
12913
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
1 dnl A placeholder for ISO C99 <wchar.h>, for platforms that have issues. |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
2 |
14079
97fc9a21a8fb
maint: update almost all copyright ranges to include 2011
Jim Meyering <meyering@redhat.com>
parents:
14020
diff
changeset
|
3 dnl Copyright (C) 2007-2011 Free Software Foundation, Inc. |
12913
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
4 dnl This file is free software; the Free Software Foundation |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
5 dnl gives unlimited permission to copy and/or distribute it, |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
6 dnl with or without modifications, as long as this notice is preserved. |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
7 |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
8 dnl Written by Eric Blake. |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
9 |
14267 | 10 # wchar_h.m4 serial 38 |
12913
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
11 |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
12 AC_DEFUN([gl_WCHAR_H], |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
13 [ |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
14 AC_REQUIRE([gl_WCHAR_H_DEFAULTS]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
15 AC_REQUIRE([gl_WCHAR_H_INLINE_OK]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
16 dnl Prepare for creating substitute <wchar.h>. |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
17 dnl Check for <wchar.h> (missing in Linux uClibc when built without wide |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
18 dnl character support). |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
19 dnl <wchar.h> is always overridden, because of GNULIB_POSIXCHECK. |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
20 gl_CHECK_NEXT_HEADERS([wchar.h]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
21 if test $ac_cv_header_wchar_h = yes; then |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
22 HAVE_WCHAR_H=1 |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
23 else |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
24 HAVE_WCHAR_H=0 |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
25 fi |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
26 AC_SUBST([HAVE_WCHAR_H]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
27 |
13887
ff73aa93842c
Ensure that <features.h> is included before __GLIBC__ is tested.
Bruno Haible <bruno@clisp.org>
parents:
13885
diff
changeset
|
28 AC_REQUIRE([gl_FEATURES_H]) |
ff73aa93842c
Ensure that <features.h> is included before __GLIBC__ is tested.
Bruno Haible <bruno@clisp.org>
parents:
13885
diff
changeset
|
29 |
12913
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
30 AC_REQUIRE([gt_TYPE_WINT_T]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
31 if test $gt_cv_c_wint_t = yes; then |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
32 HAVE_WINT_T=1 |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
33 else |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
34 HAVE_WINT_T=0 |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
35 fi |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
36 AC_SUBST([HAVE_WINT_T]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
37 |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
38 dnl Check for declarations of anything we want to poison if the |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
39 dnl corresponding gnulib module is not in use. |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
40 gl_WARN_ON_USE_PREPARE([[ |
14020
318a4063e921
Ensure all prerequisites of <wchar.h> are included.
Bruno Haible <bruno@clisp.org>
parents:
13887
diff
changeset
|
41 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before |
318a4063e921
Ensure all prerequisites of <wchar.h> are included.
Bruno Haible <bruno@clisp.org>
parents:
13887
diff
changeset
|
42 <wchar.h>. |
318a4063e921
Ensure all prerequisites of <wchar.h> are included.
Bruno Haible <bruno@clisp.org>
parents:
13887
diff
changeset
|
43 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be |
318a4063e921
Ensure all prerequisites of <wchar.h> are included.
Bruno Haible <bruno@clisp.org>
parents:
13887
diff
changeset
|
44 included before <wchar.h>. */ |
13885 | 45 #if !(defined __GLIBC__ && !defined __UCLIBC__) |
12913
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
46 # include <stddef.h> |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
47 # include <stdio.h> |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
48 # include <time.h> |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
49 #endif |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
50 #include <wchar.h> |
14268
27d6460ec7c1
New module 'wmemchr', part 2.
Bruno Haible <bruno@clisp.org>
parents:
14267
diff
changeset
|
51 ]], |
27d6460ec7c1
New module 'wmemchr', part 2.
Bruno Haible <bruno@clisp.org>
parents:
14267
diff
changeset
|
52 [btowc wctob mbsinit mbrtowc mbrlen mbsrtowcs mbsnrtowcs wcrtomb |
14280 | 53 wcsrtombs wcsnrtombs wcwidth wmemchr wmemcmp wmemcpy wmemmove wmemset |
14289 | 54 wcslen wcsnlen wcscpy wcpcpy wcsncpy wcpncpy wcscat wcsncat wcscmp |
14290 | 55 wcsncmp |
14268
27d6460ec7c1
New module 'wmemchr', part 2.
Bruno Haible <bruno@clisp.org>
parents:
14267
diff
changeset
|
56 ]) |
12913
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
57 ]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
58 |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
59 dnl Check whether <wchar.h> is usable at all. |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
60 AC_DEFUN([gl_WCHAR_H_INLINE_OK], |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
61 [ |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
62 dnl Test whether <wchar.h> suffers due to the transition from '__inline' to |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
63 dnl 'gnu_inline'. See <http://sourceware.org/bugzilla/show_bug.cgi?id=4022> |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
64 dnl and <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42440>. In summary, |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
65 dnl glibc version 2.5 or older, together with gcc version 4.3 or newer and |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
66 dnl the option -std=c99 or -std=gnu99, leads to a broken <wchar.h>. |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
67 AC_CACHE_CHECK([whether <wchar.h> uses 'inline' correctly], |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
68 [gl_cv_header_wchar_h_correct_inline], |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
69 [gl_cv_header_wchar_h_correct_inline=yes |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
70 AC_LANG_CONFTEST([ |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
71 AC_LANG_SOURCE([[#define wcstod renamed_wcstod |
14020
318a4063e921
Ensure all prerequisites of <wchar.h> are included.
Bruno Haible <bruno@clisp.org>
parents:
13887
diff
changeset
|
72 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before |
318a4063e921
Ensure all prerequisites of <wchar.h> are included.
Bruno Haible <bruno@clisp.org>
parents:
13887
diff
changeset
|
73 <wchar.h>. |
318a4063e921
Ensure all prerequisites of <wchar.h> are included.
Bruno Haible <bruno@clisp.org>
parents:
13887
diff
changeset
|
74 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be |
318a4063e921
Ensure all prerequisites of <wchar.h> are included.
Bruno Haible <bruno@clisp.org>
parents:
13887
diff
changeset
|
75 included before <wchar.h>. */ |
318a4063e921
Ensure all prerequisites of <wchar.h> are included.
Bruno Haible <bruno@clisp.org>
parents:
13887
diff
changeset
|
76 #include <stddef.h> |
318a4063e921
Ensure all prerequisites of <wchar.h> are included.
Bruno Haible <bruno@clisp.org>
parents:
13887
diff
changeset
|
77 #include <stdio.h> |
318a4063e921
Ensure all prerequisites of <wchar.h> are included.
Bruno Haible <bruno@clisp.org>
parents:
13887
diff
changeset
|
78 #include <time.h> |
12913
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
79 #include <wchar.h> |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
80 extern int zero (void); |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
81 int main () { return zero(); } |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
82 ]])]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
83 if AC_TRY_EVAL([ac_compile]); then |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
84 mv conftest.$ac_objext conftest1.$ac_objext |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
85 AC_LANG_CONFTEST([ |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
86 AC_LANG_SOURCE([[#define wcstod renamed_wcstod |
14020
318a4063e921
Ensure all prerequisites of <wchar.h> are included.
Bruno Haible <bruno@clisp.org>
parents:
13887
diff
changeset
|
87 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before |
318a4063e921
Ensure all prerequisites of <wchar.h> are included.
Bruno Haible <bruno@clisp.org>
parents:
13887
diff
changeset
|
88 <wchar.h>. |
318a4063e921
Ensure all prerequisites of <wchar.h> are included.
Bruno Haible <bruno@clisp.org>
parents:
13887
diff
changeset
|
89 BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be |
318a4063e921
Ensure all prerequisites of <wchar.h> are included.
Bruno Haible <bruno@clisp.org>
parents:
13887
diff
changeset
|
90 included before <wchar.h>. */ |
318a4063e921
Ensure all prerequisites of <wchar.h> are included.
Bruno Haible <bruno@clisp.org>
parents:
13887
diff
changeset
|
91 #include <stddef.h> |
318a4063e921
Ensure all prerequisites of <wchar.h> are included.
Bruno Haible <bruno@clisp.org>
parents:
13887
diff
changeset
|
92 #include <stdio.h> |
318a4063e921
Ensure all prerequisites of <wchar.h> are included.
Bruno Haible <bruno@clisp.org>
parents:
13887
diff
changeset
|
93 #include <time.h> |
12913
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
94 #include <wchar.h> |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
95 int zero (void) { return 0; } |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
96 ]])]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
97 if AC_TRY_EVAL([ac_compile]); then |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
98 mv conftest.$ac_objext conftest2.$ac_objext |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
99 if $CC -o conftest$ac_exeext $CFLAGS $LDFLAGS conftest1.$ac_objext conftest2.$ac_objext $LIBS >&AS_MESSAGE_LOG_FD 2>&1; then |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
100 : |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
101 else |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
102 gl_cv_header_wchar_h_correct_inline=no |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
103 fi |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
104 fi |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
105 fi |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
106 rm -f conftest1.$ac_objext conftest2.$ac_objext conftest$ac_exeext |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
107 ]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
108 if test $gl_cv_header_wchar_h_correct_inline = no; then |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
109 AC_MSG_ERROR([<wchar.h> cannot be used with this compiler ($CC $CFLAGS $CPPFLAGS). |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
110 This is a known interoperability problem of glibc <= 2.5 with gcc >= 4.3 in |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
111 C99 mode. You have four options: |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
112 - Add the flag -fgnu89-inline to CC and reconfigure, or |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
113 - Fix your include files, using parts of |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
114 <http://sourceware.org/git/?p=glibc.git;a=commitdiff;h=b037a293a48718af30d706c2e18c929d0e69a621>, or |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
115 - Use a gcc version older than 4.3, or |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
116 - Don't use the flags -std=c99 or -std=gnu99. |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
117 Configuration aborted.]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
118 fi |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
119 ]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
120 |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
121 dnl Unconditionally enables the replacement of <wchar.h>. |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
122 AC_DEFUN([gl_REPLACE_WCHAR_H], |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
123 [ |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
124 dnl This is a no-op, because <wchar.h> is always overridden. |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
125 : |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
126 ]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
127 |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
128 AC_DEFUN([gl_WCHAR_MODULE_INDICATOR], |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
129 [ |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
130 dnl Use AC_REQUIRE here, so that the default settings are expanded once only. |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
131 AC_REQUIRE([gl_WCHAR_H_DEFAULTS]) |
13066
fc8c984b0733
Factorize common .m4 code.
Bruno Haible <bruno@clisp.org>
parents:
12974
diff
changeset
|
132 gl_MODULE_INDICATOR_SET_VARIABLE([$1]) |
12974
61705dab4021
Tests of module 'wchar' in C++ mode.
Bruno Haible <bruno@clisp.org>
parents:
12913
diff
changeset
|
133 dnl Define it also as a C macro, for the benefit of the unit tests. |
13071
b2385e7b332e
Distinguish two kinds of module indicators.
Bruno Haible <bruno@clisp.org>
parents:
13066
diff
changeset
|
134 gl_MODULE_INDICATOR_FOR_TESTS([$1]) |
12913
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
135 ]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
136 |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
137 AC_DEFUN([gl_WCHAR_H_DEFAULTS], |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
138 [ |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
139 GNULIB_BTOWC=0; AC_SUBST([GNULIB_BTOWC]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
140 GNULIB_WCTOB=0; AC_SUBST([GNULIB_WCTOB]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
141 GNULIB_MBSINIT=0; AC_SUBST([GNULIB_MBSINIT]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
142 GNULIB_MBRTOWC=0; AC_SUBST([GNULIB_MBRTOWC]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
143 GNULIB_MBRLEN=0; AC_SUBST([GNULIB_MBRLEN]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
144 GNULIB_MBSRTOWCS=0; AC_SUBST([GNULIB_MBSRTOWCS]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
145 GNULIB_MBSNRTOWCS=0; AC_SUBST([GNULIB_MBSNRTOWCS]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
146 GNULIB_WCRTOMB=0; AC_SUBST([GNULIB_WCRTOMB]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
147 GNULIB_WCSRTOMBS=0; AC_SUBST([GNULIB_WCSRTOMBS]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
148 GNULIB_WCSNRTOMBS=0; AC_SUBST([GNULIB_WCSNRTOMBS]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
149 GNULIB_WCWIDTH=0; AC_SUBST([GNULIB_WCWIDTH]) |
14267 | 150 GNULIB_WMEMCHR=0; AC_SUBST([GNULIB_WMEMCHR]) |
14277 | 151 GNULIB_WMEMCMP=0; AC_SUBST([GNULIB_WMEMCMP]) |
14278 | 152 GNULIB_WMEMCPY=0; AC_SUBST([GNULIB_WMEMCPY]) |
14279 | 153 GNULIB_WMEMMOVE=0; AC_SUBST([GNULIB_WMEMMOVE]) |
14280 | 154 GNULIB_WMEMSET=0; AC_SUBST([GNULIB_WMEMSET]) |
14281 | 155 GNULIB_WCSLEN=0; AC_SUBST([GNULIB_WCSLEN]) |
14282 | 156 GNULIB_WCSNLEN=0; AC_SUBST([GNULIB_WCSNLEN]) |
14283 | 157 GNULIB_WCSCPY=0; AC_SUBST([GNULIB_WCSCPY]) |
14284 | 158 GNULIB_WCPCPY=0; AC_SUBST([GNULIB_WCPCPY]) |
14285 | 159 GNULIB_WCSNCPY=0; AC_SUBST([GNULIB_WCSNCPY]) |
14286 | 160 GNULIB_WCPNCPY=0; AC_SUBST([GNULIB_WCPNCPY]) |
14287 | 161 GNULIB_WCSCAT=0; AC_SUBST([GNULIB_WCSCAT]) |
14288 | 162 GNULIB_WCSNCAT=0; AC_SUBST([GNULIB_WCSNCAT]) |
14289 | 163 GNULIB_WCSCMP=0; AC_SUBST([GNULIB_WCSCMP]) |
14290 | 164 GNULIB_WCSNCMP=0; AC_SUBST([GNULIB_WCSNCMP]) |
12913
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
165 dnl Assume proper GNU behavior unless another module says otherwise. |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
166 HAVE_BTOWC=1; AC_SUBST([HAVE_BTOWC]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
167 HAVE_MBSINIT=1; AC_SUBST([HAVE_MBSINIT]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
168 HAVE_MBRTOWC=1; AC_SUBST([HAVE_MBRTOWC]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
169 HAVE_MBRLEN=1; AC_SUBST([HAVE_MBRLEN]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
170 HAVE_MBSRTOWCS=1; AC_SUBST([HAVE_MBSRTOWCS]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
171 HAVE_MBSNRTOWCS=1; AC_SUBST([HAVE_MBSNRTOWCS]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
172 HAVE_WCRTOMB=1; AC_SUBST([HAVE_WCRTOMB]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
173 HAVE_WCSRTOMBS=1; AC_SUBST([HAVE_WCSRTOMBS]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
174 HAVE_WCSNRTOMBS=1; AC_SUBST([HAVE_WCSNRTOMBS]) |
14267 | 175 HAVE_WMEMCHR=1; AC_SUBST([HAVE_WMEMCHR]) |
14277 | 176 HAVE_WMEMCMP=1; AC_SUBST([HAVE_WMEMCMP]) |
14278 | 177 HAVE_WMEMCPY=1; AC_SUBST([HAVE_WMEMCPY]) |
14279 | 178 HAVE_WMEMMOVE=1; AC_SUBST([HAVE_WMEMMOVE]) |
14280 | 179 HAVE_WMEMSET=1; AC_SUBST([HAVE_WMEMSET]) |
14281 | 180 HAVE_WCSLEN=1; AC_SUBST([HAVE_WCSLEN]) |
14282 | 181 HAVE_WCSNLEN=1; AC_SUBST([HAVE_WCSNLEN]) |
14283 | 182 HAVE_WCSCPY=1; AC_SUBST([HAVE_WCSCPY]) |
14284 | 183 HAVE_WCPCPY=1; AC_SUBST([HAVE_WCPCPY]) |
14285 | 184 HAVE_WCSNCPY=1; AC_SUBST([HAVE_WCSNCPY]) |
14286 | 185 HAVE_WCPNCPY=1; AC_SUBST([HAVE_WCPNCPY]) |
14287 | 186 HAVE_WCSCAT=1; AC_SUBST([HAVE_WCSCAT]) |
14288 | 187 HAVE_WCSNCAT=1; AC_SUBST([HAVE_WCSNCAT]) |
14289 | 188 HAVE_WCSCMP=1; AC_SUBST([HAVE_WCSCMP]) |
14290 | 189 HAVE_WCSNCMP=1; AC_SUBST([HAVE_WCSNCMP]) |
12913
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
190 HAVE_DECL_WCTOB=1; AC_SUBST([HAVE_DECL_WCTOB]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
191 HAVE_DECL_WCWIDTH=1; AC_SUBST([HAVE_DECL_WCWIDTH]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
192 REPLACE_MBSTATE_T=0; AC_SUBST([REPLACE_MBSTATE_T]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
193 REPLACE_BTOWC=0; AC_SUBST([REPLACE_BTOWC]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
194 REPLACE_WCTOB=0; AC_SUBST([REPLACE_WCTOB]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
195 REPLACE_MBSINIT=0; AC_SUBST([REPLACE_MBSINIT]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
196 REPLACE_MBRTOWC=0; AC_SUBST([REPLACE_MBRTOWC]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
197 REPLACE_MBRLEN=0; AC_SUBST([REPLACE_MBRLEN]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
198 REPLACE_MBSRTOWCS=0; AC_SUBST([REPLACE_MBSRTOWCS]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
199 REPLACE_MBSNRTOWCS=0; AC_SUBST([REPLACE_MBSNRTOWCS]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
200 REPLACE_WCRTOMB=0; AC_SUBST([REPLACE_WCRTOMB]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
201 REPLACE_WCSRTOMBS=0; AC_SUBST([REPLACE_WCSRTOMBS]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
202 REPLACE_WCSNRTOMBS=0; AC_SUBST([REPLACE_WCSNRTOMBS]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
203 REPLACE_WCWIDTH=0; AC_SUBST([REPLACE_WCWIDTH]) |
6a1b2eb4c331
More consistent naming of *.m4 files.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
204 ]) |