2
Copyright (C) 2007-2012 Free Software Foundation, Inc.
4
This program is free software: you can redistribute it and/or modify
5
it under the terms of the GNU Lesser General Public License as published by
6
the Free Software Foundation; either version 2.1 of the License, or
7
(at your option) any later version.
9
This program is distributed in the hope that it will be useful,
10
but WITHOUT ANY WARRANTY; without even the implied warranty of
11
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
GNU Lesser General Public License for more details.
14
You should have received a copy of the GNU Lesser General Public License
15
along with this program. If not, see <http://www.gnu.org/licenses/>. */
17
#ifndef _@GUARD_PREFIX@_LOCALE_H
20
@PRAGMA_SYSTEM_HEADER@
24
/* The include_next requires a split double-inclusion guard. */
25
#@INCLUDE_NEXT@ @NEXT_LOCALE_H@
27
#ifndef _@GUARD_PREFIX@_LOCALE_H
28
#define _@GUARD_PREFIX@_LOCALE_H
30
/* NetBSD 5.0 mis-defines NULL. */
33
/* MacOS X 10.5 defines the locale_t type in <xlocale.h>. */
38
/* The definitions of _GL_FUNCDECL_RPL etc. are copied here. */
40
/* The definition of _GL_ARG_NONNULL is copied here. */
42
/* The definition of _GL_WARN_ON_USE is copied here. */
44
/* The LC_MESSAGES locale category is specified in POSIX, but not in ISO C.
45
On systems that don't define it, use the same value as GNU libintl. */
46
#if !defined LC_MESSAGES
47
# define LC_MESSAGES 1729
50
/* Bionic libc's 'struct lconv' is just a dummy. */
51
#if @REPLACE_STRUCT_LCONV@
52
# define lconv rpl_lconv
55
/* All 'char *' are actually 'const char *'. */
57
/* Members that depend on the LC_NUMERIC category of the locale. See
58
<http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap07.html#tag_07_03_04> */
60
/* Symbol used as decimal point. */
62
/* Symbol used to separate groups of digits to the left of the decimal
65
/* Definition of the size of groups of digits to the left of the decimal
69
/* Members that depend on the LC_MONETARY category of the locale. See
70
<http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap07.html#tag_07_03_03> */
72
/* Symbol used as decimal point. */
73
char *mon_decimal_point;
74
/* Symbol used to separate groups of digits to the left of the decimal
76
char *mon_thousands_sep;
77
/* Definition of the size of groups of digits to the left of the decimal
80
/* Sign used to indicate a value >= 0. */
82
/* Sign used to indicate a value < 0. */
85
/* For formatting local currency. */
86
/* Currency symbol (3 characters) followed by separator (1 character). */
87
char *currency_symbol;
88
/* Number of digits after the decimal point. */
90
/* For values >= 0: 1 if the currency symbol precedes the number, 0 if it
91
comes after the number. */
93
/* For values >= 0: Position of the sign. */
95
/* For values >= 0: Placement of spaces between currency symbol, sign, and
98
/* For values < 0: 1 if the currency symbol precedes the number, 0 if it
99
comes after the number. */
101
/* For values < 0: Position of the sign. */
103
/* For values < 0: Placement of spaces between currency symbol, sign, and
107
/* For formatting international currency. */
108
/* Currency symbol (3 characters) followed by separator (1 character). */
109
char *int_curr_symbol;
110
/* Number of digits after the decimal point. */
111
char int_frac_digits;
112
/* For values >= 0: 1 if the currency symbol precedes the number, 0 if it
113
comes after the number. */
114
char int_p_cs_precedes;
115
/* For values >= 0: Position of the sign. */
116
char int_p_sign_posn;
117
/* For values >= 0: Placement of spaces between currency symbol, sign, and
119
char int_p_sep_by_space;
120
/* For values < 0: 1 if the currency symbol precedes the number, 0 if it
121
comes after the number. */
122
char int_n_cs_precedes;
123
/* For values < 0: Position of the sign. */
124
char int_n_sign_posn;
125
/* For values < 0: Placement of spaces between currency symbol, sign, and
127
char int_n_sep_by_space;
131
#if @GNULIB_LOCALECONV@
132
# if @REPLACE_LOCALECONV@
133
# if !(defined __cplusplus && defined GNULIB_NAMESPACE)
135
# define localeconv rpl_localeconv
137
_GL_FUNCDECL_RPL (localeconv, struct lconv *, (void));
138
_GL_CXXALIAS_RPL (localeconv, struct lconv *, (void));
140
_GL_CXXALIAS_SYS (localeconv, struct lconv *, (void));
142
_GL_CXXALIASWARN (localeconv);
143
#elif @REPLACE_STRUCT_LCONV@
145
# define localeconv localeconv_used_without_requesting_gnulib_module_localeconv
146
#elif defined GNULIB_POSIXCHECK
148
# if HAVE_RAW_DECL_LOCALECONV
149
_GL_WARN_ON_USE (localeconv,
150
"localeconv returns too few information on some platforms - "
151
"use gnulib module localeconv for portability");
155
#if @GNULIB_SETLOCALE@
156
# if @REPLACE_SETLOCALE@
157
# if !(defined __cplusplus && defined GNULIB_NAMESPACE)
159
# define setlocale rpl_setlocale
160
# define GNULIB_defined_setlocale 1
162
_GL_FUNCDECL_RPL (setlocale, char *, (int category, const char *locale));
163
_GL_CXXALIAS_RPL (setlocale, char *, (int category, const char *locale));
165
_GL_CXXALIAS_SYS (setlocale, char *, (int category, const char *locale));
167
_GL_CXXALIASWARN (setlocale);
168
#elif defined GNULIB_POSIXCHECK
170
# if HAVE_RAW_DECL_SETLOCALE
171
_GL_WARN_ON_USE (setlocale, "setlocale works differently on native Windows - "
172
"use gnulib module setlocale for portability");
176
#if @GNULIB_DUPLOCALE@
177
# if @REPLACE_DUPLOCALE@
178
# if !(defined __cplusplus && defined GNULIB_NAMESPACE)
180
# define duplocale rpl_duplocale
182
_GL_FUNCDECL_RPL (duplocale, locale_t, (locale_t locale) _GL_ARG_NONNULL ((1)));
183
_GL_CXXALIAS_RPL (duplocale, locale_t, (locale_t locale));
185
# if @HAVE_DUPLOCALE@
186
_GL_CXXALIAS_SYS (duplocale, locale_t, (locale_t locale));
189
# if @HAVE_DUPLOCALE@
190
_GL_CXXALIASWARN (duplocale);
192
#elif defined GNULIB_POSIXCHECK
194
# if HAVE_RAW_DECL_DUPLOCALE
195
_GL_WARN_ON_USE (duplocale, "duplocale is buggy on some glibc systems - "
196
"use gnulib module duplocale for portability");
200
#endif /* _@GUARD_PREFIX@_LOCALE_H */
201
#endif /* _@GUARD_PREFIX@_LOCALE_H */