1
1
/* Determine a canonical name for the current locale's character encoding.
3
Copyright (C) 2000-2002 Free Software Foundation, Inc.
3
Copyright (C) 2000-2003 Free Software Foundation, Inc.
5
5
This program is free software; you can redistribute it and/or modify it
6
6
under the terms of the GNU Library General Public License as published
77
86
# define ISSLASH(C) ((C) == DIRECTORY_SEPARATOR)
80
#ifdef HAVE_GETC_UNLOCKED
89
#if HAVE_DECL_GETC_UNLOCKED
82
91
# define getc getc_unlocked
86
/* When compiling with "gcc -x c++", produce a function with C linkage. */
87
extern "C" const char * locale_charset (void);
90
94
/* The following static variable is declared 'volatile' to avoid a
91
95
possible multithread problem in the function get_charset_aliases. If we
92
96
are running in a threaded environment, and if two threads initialize
208
/* To avoid the troubles of an extra file charset.alias_vms in the
209
sources of many GNU packages, simply inline the aliases here. */
210
/* The list of encodings is taken from the OpenVMS 7.3-1 documentation
211
"Compaq C Run-Time Library Reference Manual for OpenVMS systems"
212
section 10.7 "Handling Different Character Sets". */
213
cp = "ISO8859-1" "\0" "ISO-8859-1" "\0"
214
"ISO8859-2" "\0" "ISO-8859-2" "\0"
215
"ISO8859-5" "\0" "ISO-8859-5" "\0"
216
"ISO8859-7" "\0" "ISO-8859-7" "\0"
217
"ISO8859-8" "\0" "ISO-8859-8" "\0"
218
"ISO8859-9" "\0" "ISO-8859-9" "\0"
220
"eucJP" "\0" "EUC-JP" "\0"
221
"SJIS" "\0" "SHIFT_JIS" "\0"
222
"DECKANJI" "\0" "DEC-KANJI" "\0"
223
"SDECKANJI" "\0" "EUC-JP" "\0"
225
"eucTW" "\0" "EUC-TW" "\0"
226
"DECHANYU" "\0" "DEC-HANYU" "\0"
227
"DECHANZI" "\0" "GB2312" "\0"
229
"DECKOREAN" "\0" "EUC-KR" "\0";
203
233
/* To avoid the troubles of installing a separate file in the same
204
234
directory as the DLL and of retrieving the DLL's directory at
205
235
runtime, simply inline the aliases here. */
208
237
cp = "CP936" "\0" "GBK" "\0"
209
238
"CP1361" "\0" "JOHAB" "\0"
210
239
"CP20127" "\0" "ASCII" "\0"