]> git.saurik.com Git - bison.git/blob - intl/config.charset
* Gettext 0.11.1.
[bison.git] / intl / config.charset
1 #! /bin/sh
2 # Output a system dependent table of character encoding aliases.
3 #
4 # Copyright (C) 2000-2002 Free Software Foundation, Inc.
5 #
6 # This program is free software; you can redistribute it and/or modify it
7 # under the terms of the GNU Library General Public License as published
8 # by the Free Software Foundation; either version 2, or (at your option)
9 # any later version.
10 #
11 # This program is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 # Library General Public License for more details.
15 #
16 # You should have received a copy of the GNU Library General Public
17 # License along with this program; if not, write to the Free Software
18 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
19 # USA.
20 #
21 # The table consists of lines of the form
22 # ALIAS CANONICAL
23 #
24 # ALIAS is the (system dependent) result of "nl_langinfo (CODESET)".
25 # ALIAS is compared in a case sensitive way.
26 #
27 # CANONICAL is the GNU canonical name for this character encoding.
28 # It must be an encoding supported by libiconv. Support by GNU libc is
29 # also desirable. CANONICAL is case insensitive. Usually an upper case
30 # MIME charset name is preferred.
31 # The current list of GNU canonical charset names is as follows.
32 #
33 # name used by which systems a MIME name?
34 # ASCII, ANSI_X3.4-1968 glibc solaris freebsd
35 # ISO-8859-1 glibc aix hpux irix osf solaris freebsd yes
36 # ISO-8859-2 glibc aix hpux irix osf solaris freebsd yes
37 # ISO-8859-3 glibc yes
38 # ISO-8859-4 osf solaris freebsd yes
39 # ISO-8859-5 glibc aix hpux irix osf solaris freebsd yes
40 # ISO-8859-6 glibc aix hpux solaris yes
41 # ISO-8859-7 glibc aix hpux irix osf solaris yes
42 # ISO-8859-8 glibc aix hpux osf solaris yes
43 # ISO-8859-9 glibc aix hpux irix osf solaris yes
44 # ISO-8859-13 glibc
45 # ISO-8859-15 glibc aix osf solaris freebsd
46 # KOI8-R glibc solaris freebsd yes
47 # KOI8-U glibc freebsd yes
48 # CP437 dos
49 # CP775 dos
50 # CP850 aix osf dos
51 # CP852 dos
52 # CP855 dos
53 # CP856 aix
54 # CP857 dos
55 # CP861 dos
56 # CP862 dos
57 # CP864 dos
58 # CP865 dos
59 # CP866 freebsd dos
60 # CP869 dos
61 # CP874 win32 dos
62 # CP922 aix
63 # CP932 aix win32 dos
64 # CP943 aix
65 # CP949 osf win32 dos
66 # CP950 win32 dos
67 # CP1046 aix
68 # CP1124 aix
69 # CP1129 aix
70 # CP1250 win32
71 # CP1251 glibc win32
72 # CP1252 aix win32
73 # CP1253 win32
74 # CP1254 win32
75 # CP1255 win32
76 # CP1256 win32
77 # CP1257 win32
78 # GB2312 glibc aix hpux irix solaris freebsd yes
79 # EUC-JP glibc aix hpux irix osf solaris freebsd yes
80 # EUC-KR glibc aix hpux irix osf solaris freebsd yes
81 # EUC-TW glibc aix hpux irix osf solaris
82 # BIG5 glibc aix hpux osf solaris freebsd yes
83 # BIG5-HKSCS glibc
84 # GBK aix osf win32 dos
85 # GB18030 glibc
86 # SHIFT_JIS hpux osf solaris freebsd yes
87 # JOHAB glibc win32
88 # TIS-620 glibc aix hpux osf solaris
89 # VISCII glibc yes
90 # HP-ROMAN8 hpux
91 # HP-ARABIC8 hpux
92 # HP-GREEK8 hpux
93 # HP-HEBREW8 hpux
94 # HP-TURKISH8 hpux
95 # HP-KANA8 hpux
96 # DEC-KANJI osf
97 # DEC-HANYU osf
98 # UTF-8 glibc aix hpux osf solaris yes
99 #
100 # Note: Names which are not marked as being a MIME name should not be used in
101 # Internet protocols for information interchange (mail, news, etc.).
102 #
103 # Note: ASCII and ANSI_X3.4-1968 are synonymous canonical names. Applications
104 # must understand both names and treat them as equivalent.
105 #
106 # The first argument passed to this file is the canonical host specification,
107 # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM
108 # or
109 # CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM
110
111 host="$1"
112 os=`echo "$host" | sed -e 's/^[^-]*-[^-]*-\(.*\)$/\1/'`
113 echo "# This file contains a table of character encoding aliases,"
114 echo "# suitable for operating system '${os}'."
115 echo "# It was automatically generated from config.charset."
116 # List of references, updated during installation:
117 echo "# Packages using this file: "
118 case "$os" in
119 linux* | *-gnu*)
120 # With glibc-2.1 or newer, we don't need any canonicalization,
121 # because glibc has iconv and both glibc and libiconv support all
122 # GNU canonical names directly. Therefore, the Makefile does not
123 # need to install the alias file at all.
124 # The following applies only to glibc-2.0.x and older libcs.
125 echo "ISO_646.IRV:1983 ASCII"
126 ;;
127 aix*)
128 echo "ISO8859-1 ISO-8859-1"
129 echo "ISO8859-2 ISO-8859-2"
130 echo "ISO8859-5 ISO-8859-5"
131 echo "ISO8859-6 ISO-8859-6"
132 echo "ISO8859-7 ISO-8859-7"
133 echo "ISO8859-8 ISO-8859-8"
134 echo "ISO8859-9 ISO-8859-9"
135 echo "ISO8859-15 ISO-8859-15"
136 echo "IBM-850 CP850"
137 echo "IBM-856 CP856"
138 echo "IBM-921 ISO-8859-13"
139 echo "IBM-922 CP922"
140 echo "IBM-932 CP932"
141 echo "IBM-943 CP943"
142 echo "IBM-1046 CP1046"
143 echo "IBM-1124 CP1124"
144 echo "IBM-1129 CP1129"
145 echo "IBM-1252 CP1252"
146 echo "IBM-eucCN GB2312"
147 echo "IBM-eucJP EUC-JP"
148 echo "IBM-eucKR EUC-KR"
149 echo "IBM-eucTW EUC-TW"
150 echo "big5 BIG5"
151 echo "GBK GBK"
152 echo "TIS-620 TIS-620"
153 echo "UTF-8 UTF-8"
154 ;;
155 hpux*)
156 echo "iso88591 ISO-8859-1"
157 echo "iso88592 ISO-8859-2"
158 echo "iso88595 ISO-8859-5"
159 echo "iso88596 ISO-8859-6"
160 echo "iso88597 ISO-8859-7"
161 echo "iso88598 ISO-8859-8"
162 echo "iso88599 ISO-8859-9"
163 echo "iso885915 ISO-8859-15"
164 echo "roman8 HP-ROMAN8"
165 echo "arabic8 HP-ARABIC8"
166 echo "greek8 HP-GREEK8"
167 echo "hebrew8 HP-HEBREW8"
168 echo "turkish8 HP-TURKISH8"
169 echo "kana8 HP-KANA8"
170 echo "tis620 TIS-620"
171 echo "big5 BIG5"
172 echo "eucJP EUC-JP"
173 echo "eucKR EUC-KR"
174 echo "eucTW EUC-TW"
175 echo "hp15CN GB2312"
176 #echo "ccdc ?" # what is this?
177 echo "SJIS SHIFT_JIS"
178 echo "utf8 UTF-8"
179 ;;
180 irix*)
181 echo "ISO8859-1 ISO-8859-1"
182 echo "ISO8859-2 ISO-8859-2"
183 echo "ISO8859-5 ISO-8859-5"
184 echo "ISO8859-7 ISO-8859-7"
185 echo "ISO8859-9 ISO-8859-9"
186 echo "eucCN GB2312"
187 echo "eucJP EUC-JP"
188 echo "eucKR EUC-KR"
189 echo "eucTW EUC-TW"
190 ;;
191 osf*)
192 echo "ISO8859-1 ISO-8859-1"
193 echo "ISO8859-2 ISO-8859-2"
194 echo "ISO8859-4 ISO-8859-4"
195 echo "ISO8859-5 ISO-8859-5"
196 echo "ISO8859-7 ISO-8859-7"
197 echo "ISO8859-8 ISO-8859-8"
198 echo "ISO8859-9 ISO-8859-9"
199 echo "ISO8859-15 ISO-8859-15"
200 echo "cp850 CP850"
201 echo "big5 BIG5"
202 echo "dechanyu DEC-HANYU"
203 echo "dechanzi GB2312"
204 echo "deckanji DEC-KANJI"
205 echo "deckorean EUC-KR"
206 echo "eucJP EUC-JP"
207 echo "eucKR EUC-KR"
208 echo "eucTW EUC-TW"
209 echo "GBK GBK"
210 echo "KSC5601 CP949"
211 echo "sdeckanji EUC-JP"
212 echo "SJIS SHIFT_JIS"
213 echo "TACTIS TIS-620"
214 echo "UTF-8 UTF-8"
215 ;;
216 solaris*)
217 echo "646 ASCII"
218 echo "ISO8859-1 ISO-8859-1"
219 echo "ISO8859-2 ISO-8859-2"
220 echo "ISO8859-4 ISO-8859-4"
221 echo "ISO8859-5 ISO-8859-5"
222 echo "ISO8859-6 ISO-8859-6"
223 echo "ISO8859-7 ISO-8859-7"
224 echo "ISO8859-8 ISO-8859-8"
225 echo "ISO8859-9 ISO-8859-9"
226 echo "ISO8859-15 ISO-8859-15"
227 echo "koi8-r KOI8-R"
228 echo "BIG5 BIG5"
229 echo "gb2312 GB2312"
230 echo "cns11643 EUC-TW"
231 echo "5601 EUC-KR"
232 echo "eucJP EUC-JP"
233 echo "PCK SHIFT_JIS"
234 echo "TIS620.2533 TIS-620"
235 #echo "sun_eu_greek ?" # what is this?
236 echo "UTF-8 UTF-8"
237 ;;
238 freebsd* | os2*)
239 # FreeBSD 4.2 doesn't have nl_langinfo(CODESET); therefore
240 # localcharset.c falls back to using the full locale name
241 # from the environment variables.
242 # Likewise for OS/2. OS/2 has XFree86 just like FreeBSD. Just
243 # reuse FreeBSD's locale data for OS/2.
244 echo "C ASCII"
245 echo "US-ASCII ASCII"
246 for l in la_LN lt_LN; do
247 echo "$l.ASCII ASCII"
248 done
249 for l in da_DK de_AT de_CH de_DE en_AU en_CA en_GB en_US es_ES \
250 fi_FI fr_BE fr_CA fr_CH fr_FR is_IS it_CH it_IT la_LN \
251 lt_LN nl_BE nl_NL no_NO pt_PT sv_SE; do
252 echo "$l.ISO_8859-1 ISO-8859-1"
253 echo "$l.DIS_8859-15 ISO-8859-15"
254 done
255 for l in cs_CZ hr_HR hu_HU la_LN lt_LN pl_PL sl_SI; do
256 echo "$l.ISO_8859-2 ISO-8859-2"
257 done
258 for l in la_LN lt_LT; do
259 echo "$l.ISO_8859-4 ISO-8859-4"
260 done
261 for l in ru_RU ru_SU; do
262 echo "$l.KOI8-R KOI8-R"
263 echo "$l.ISO_8859-5 ISO-8859-5"
264 echo "$l.CP866 CP866"
265 done
266 echo "uk_UA.KOI8-U KOI8-U"
267 echo "zh_TW.BIG5 BIG5"
268 echo "zh_TW.Big5 BIG5"
269 echo "zh_CN.EUC GB2312"
270 echo "ja_JP.EUC EUC-JP"
271 echo "ja_JP.SJIS SHIFT_JIS"
272 echo "ja_JP.Shift_JIS SHIFT_JIS"
273 echo "ko_KR.EUC EUC-KR"
274 ;;
275 netbsd*)
276 echo "646 ASCII"
277 echo "ISO8859-1 ISO-8859-1"
278 echo "ISO8859-2 ISO-8859-2"
279 echo "ISO8859-4 ISO-8859-4"
280 echo "ISO8859-5 ISO-8859-5"
281 echo "ISO8859-15 ISO-8859-15"
282 echo "eucCN GB2312"
283 echo "eucJP EUC-JP"
284 echo "eucKR EUC-KR"
285 echo "eucTW EUC-TW"
286 echo "BIG5 BIG5"
287 echo "SJIS SHIFT_JIS"
288 ;;
289 beos*)
290 # BeOS has a single locale, and it has UTF-8 encoding.
291 echo "* UTF-8"
292 ;;
293 msdosdjgpp*)
294 # DJGPP 2.03 doesn't have nl_langinfo(CODESET); therefore
295 # localcharset.c falls back to using the full locale name
296 # from the environment variables.
297 echo "#"
298 echo "# The encodings given here may not all be correct."
299 echo "# If you find that the encoding given for your language and"
300 echo "# country is not the one your DOS machine actually uses, just"
301 echo "# correct it in this file, and send a mail to"
302 echo "# Juan Manuel Guerrero <st001906@hrz1.hrz.tu-darmstadt.de>"
303 echo "# and Bruno Haible <haible@clisp.cons.org>."
304 echo "#"
305 echo "C ASCII"
306 # ISO-8859-1 languages
307 echo "ca CP850"
308 echo "ca_ES CP850"
309 echo "da CP865" # not CP850 ??
310 echo "da_DK CP865" # not CP850 ??
311 echo "de CP850"
312 echo "de_AT CP850"
313 echo "de_CH CP850"
314 echo "de_DE CP850"
315 echo "en CP850"
316 echo "en_AU CP850" # not CP437 ??
317 echo "en_CA CP850"
318 echo "en_GB CP850"
319 echo "en_NZ CP437"
320 echo "en_US CP437"
321 echo "en_ZA CP850" # not CP437 ??
322 echo "es CP850"
323 echo "es_AR CP850"
324 echo "es_BO CP850"
325 echo "es_CL CP850"
326 echo "es_CO CP850"
327 echo "es_CR CP850"
328 echo "es_CU CP850"
329 echo "es_DO CP850"
330 echo "es_EC CP850"
331 echo "es_ES CP850"
332 echo "es_GT CP850"
333 echo "es_HN CP850"
334 echo "es_MX CP850"
335 echo "es_NI CP850"
336 echo "es_PA CP850"
337 echo "es_PY CP850"
338 echo "es_PE CP850"
339 echo "es_SV CP850"
340 echo "es_UY CP850"
341 echo "es_VE CP850"
342 echo "et CP850"
343 echo "et_EE CP850"
344 echo "eu CP850"
345 echo "eu_ES CP850"
346 echo "fi CP850"
347 echo "fi_FI CP850"
348 echo "fr CP850"
349 echo "fr_BE CP850"
350 echo "fr_CA CP850"
351 echo "fr_CH CP850"
352 echo "fr_FR CP850"
353 echo "ga CP850"
354 echo "ga_IE CP850"
355 echo "gd CP850"
356 echo "gd_GB CP850"
357 echo "gl CP850"
358 echo "gl_ES CP850"
359 echo "id CP850" # not CP437 ??
360 echo "id_ID CP850" # not CP437 ??
361 echo "is CP861" # not CP850 ??
362 echo "is_IS CP861" # not CP850 ??
363 echo "it CP850"
364 echo "it_CH CP850"
365 echo "it_IT CP850"
366 echo "lt CP775"
367 echo "lt_LT CP775"
368 echo "lv CP775"
369 echo "lv_LV CP775"
370 echo "nb CP865" # not CP850 ??
371 echo "nb_NO CP865" # not CP850 ??
372 echo "nl CP850"
373 echo "nl_BE CP850"
374 echo "nl_NL CP850"
375 echo "nn CP865" # not CP850 ??
376 echo "nn_NO CP865" # not CP850 ??
377 echo "no CP865" # not CP850 ??
378 echo "no_NO CP865" # not CP850 ??
379 echo "pt CP850"
380 echo "pt_BR CP850"
381 echo "pt_PT CP850"
382 echo "sv CP850"
383 echo "sv_SE CP850"
384 # ISO-8859-2 languages
385 echo "cs CP852"
386 echo "cs_CZ CP852"
387 echo "hr CP852"
388 echo "hr_HR CP852"
389 echo "hu CP852"
390 echo "hu_HU CP852"
391 echo "pl CP852"
392 echo "pl_PL CP852"
393 echo "ro CP852"
394 echo "ro_RO CP852"
395 echo "sk CP852"
396 echo "sk_SK CP852"
397 echo "sl CP852"
398 echo "sl_SI CP852"
399 echo "sq CP852"
400 echo "sq_AL CP852"
401 echo "sr CP852" # CP852 or CP866 or CP855 ??
402 echo "sr_YU CP852" # CP852 or CP866 or CP855 ??
403 # ISO-8859-3 languages
404 echo "mt CP850"
405 echo "mt_MT CP850"
406 # ISO-8859-5 languages
407 echo "be CP866"
408 echo "be_BE CP866"
409 echo "bg CP866" # not CP855 ??
410 echo "bg_BG CP866" # not CP855 ??
411 echo "mk CP866" # not CP855 ??
412 echo "mk_MK CP866" # not CP855 ??
413 echo "ru CP866"
414 echo "ru_RU CP866"
415 # ISO-8859-6 languages
416 echo "ar CP864"
417 echo "ar_AE CP864"
418 echo "ar_DZ CP864"
419 echo "ar_EG CP864"
420 echo "ar_IQ CP864"
421 echo "ar_IR CP864"
422 echo "ar_JO CP864"
423 echo "ar_KW CP864"
424 echo "ar_MA CP864"
425 echo "ar_OM CP864"
426 echo "ar_QA CP864"
427 echo "ar_SA CP864"
428 echo "ar_SY CP864"
429 # ISO-8859-7 languages
430 echo "el CP869"
431 echo "el_GR CP869"
432 # ISO-8859-8 languages
433 echo "he CP862"
434 echo "he_IL CP862"
435 # ISO-8859-9 languages
436 echo "tr CP857"
437 echo "tr_TR CP857"
438 # Japanese
439 echo "ja CP932"
440 echo "ja_JP CP932"
441 # Chinese
442 echo "zh_CN GBK"
443 echo "zh_TW CP950" # not CP938 ??
444 # Korean
445 echo "kr CP949" # not CP934 ??
446 echo "kr_KR CP949" # not CP934 ??
447 # Thai
448 echo "th CP874"
449 echo "th_TH CP874"
450 # Other
451 echo "eo CP850"
452 echo "eo_EO CP850"
453 ;;
454 esac