.
[glibc/history.git] / iconvdata / tst-tables.sh
blob506adbcd7c26e1317b742828f8bdf3a94ee9ff6a
1 #!/bin/sh
2 # Copyright (C) 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
3 # This file is part of the GNU C Library.
4 # Contributed by Bruno Haible <haible@clisp.cons.org>, 2000.
7 # The GNU C Library is free software; you can redistribute it and/or
8 # modify it under the terms of the GNU Lesser General Public
9 # License as published by the Free Software Foundation; either
10 # version 2.1 of the License, or (at your option) any later version.
12 # The GNU C Library is distributed in the hope that it will be useful,
13 # but WITHOUT ANY WARRANTY; without even the implied warranty of
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 # Lesser General Public License for more details.
17 # You should have received a copy of the GNU Lesser General Public
18 # License along with the GNU C Library; if not, write to the Free
19 # Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
20 # 02111-1307 USA.
22 # Checks that the iconv() implementation (in both directions) for the
23 # stateless encodings agrees with the corresponding charmap table.
25 common_objpfx=$1
26 objpfx=$2
28 status=0
30 cat <<EOF |
31 # Single-byte and other "small" encodings come here.
32 # Keep this list in the same order as gconv-modules.
34 # charset name table name comment
35 ASCII ANSI_X3.4-1968
36 ISO646-GB BS_4730
37 ISO646-CA CSA_Z243.4-1985-1
38 ISO646-CA2 CSA_Z243.4-1985-2
39 ISO646-DE DIN_66003
40 ISO646-DK DS_2089
41 ISO646-ES ES
42 ISO646-ES2 ES2
43 ISO646-CN GB_1988-80
44 ISO646-IT IT
45 ISO646-JP JIS_C6220-1969-RO
46 ISO646-JP-OCR-B JIS_C6229-1984-B
47 ISO646-YU JUS_I.B1.002
48 ISO646-KR KSC5636
49 ISO646-HU MSZ_7795.3
50 ISO646-CU NC_NC00-10
51 ISO646-FR NF_Z_62-010
52 ISO646-FR1 NF_Z_62-010_1973
53 ISO646-NO NS_4551-1
54 ISO646-NO2 NS_4551-2
55 ISO646-PT PT
56 ISO646-PT2 PT2
57 ISO646-SE SEN_850200_B
58 ISO646-SE2 SEN_850200_C
59 ISO-8859-1
60 ISO-8859-2
61 ISO-8859-3
62 ISO-8859-4
63 ISO-8859-5
64 ISO-8859-6
65 ISO-8859-7
66 ISO-8859-8
67 ISO-8859-9
68 ISO-8859-10
69 ISO-8859-11
70 ISO-8859-13
71 ISO-8859-14
72 ISO-8859-15
73 ISO-8859-16
74 T.61-8BIT
75 ISO_6937
76 #ISO_6937-2 ISO-IR-90 Handling of combining marks is broken
77 KOI-8
78 KOI8-R
79 LATIN-GREEK
80 LATIN-GREEK-1
81 HP-ROMAN8
82 EBCDIC-AT-DE
83 EBCDIC-AT-DE-A
84 EBCDIC-CA-FR
85 EBCDIC-DK-NO
86 EBCDIC-DK-NO-A
87 EBCDIC-ES
88 EBCDIC-ES-A
89 EBCDIC-ES-S
90 EBCDIC-FI-SE
91 EBCDIC-FI-SE-A
92 EBCDIC-FR
93 EBCDIC-IS-FRISS
94 EBCDIC-IT
95 EBCDIC-PT
96 EBCDIC-UK
97 EBCDIC-US
98 IBM037
99 IBM038
100 IBM256
101 IBM273
102 IBM274
103 IBM275
104 IBM277
105 IBM278
106 IBM280
107 IBM281
108 IBM284
109 IBM285
110 IBM290
111 IBM297
112 IBM420
113 IBM423
114 IBM424
115 IBM437
116 IBM500
117 IBM850
118 IBM851
119 IBM852
120 IBM855
121 IBM856
122 IBM857
123 IBM860
124 IBM861
125 IBM862
126 IBM863
127 IBM864
128 IBM865
129 IBM866
130 IBM866NAV
131 IBM868
132 IBM869
133 IBM870
134 IBM871
135 IBM875
136 IBM880
137 IBM891
138 IBM903
139 IBM904
140 IBM905
141 IBM918
142 IBM922
143 IBM1004
144 IBM1026
145 #IBM1046 Differs from the AIX and JDK converters
146 IBM1047
147 IBM1124
148 IBM1129
149 IBM1160
150 IBM1161
151 IBM1132
152 IBM1133
153 IBM1162
154 IBM1163
155 IBM1164
156 CP1125
157 CP1250
158 CP1251
159 CP1252
160 CP1253
161 CP1254
162 CP1255
163 CP1256
164 CP1257
165 CP1258
166 IBM874
167 CP737
168 CP775
169 MACINTOSH
170 IEC_P27-1
171 ASMO_449
172 ISO-IR-99 ANSI_X3.110-1983
173 ISO-IR-139 CSN_369103
175 DEC-MCS
176 ECMA-CYRILLIC
177 ISO-IR-153 GOST_19768-74
178 GREEK-CCITT
179 GREEK7
180 GREEK7-OLD
181 INIS
182 INIS-8
183 INIS-CYRILLIC
184 ISO_2033 ISO_2033-1983
185 ISO_5427
186 ISO_5427-EXT
187 #ISO_5428 Handling of combining marks is broken
188 ISO_10367-BOX
189 MAC-IS
190 MAC-UK
191 CP10007
192 NATS-DANO
193 NATS-SEFI
194 WIN-SAMI-2 SAMI-WS2
195 ISO-IR-197
196 TIS-620
197 KOI8-U
198 #ISIRI-3342 This charset concept is completely broken
199 VISCII
200 KOI8-T
201 GEORGIAN-PS
202 GEORGIAN-ACADEMY
203 ISO-IR-209
204 MAC-SAMI
205 ARMSCII-8
206 TCVN5712-1
207 TSCII
208 PT154
209 RK1048
212 # Multibyte encodings come here
214 SJIS SHIFT_JIS
215 CP932 WINDOWS-31J
216 #IBM932 This converter looks quite strange
217 #IBM943 This converter looks quite strange
218 EUC-KR
219 CP949
220 JOHAB
221 BIG5
222 BIG5HKSCS BIG5-HKSCS
223 EUC-JP
224 EUC-JP-MS
225 EUC-CN GB2312
227 EUC-TW
228 GB18030
229 EUC-JISX0213
230 SHIFT_JISX0213
232 # Stateful encodings not testable this way
234 #IBM930
235 #IBM933
236 #IBM935
237 #IBM937
238 #IBM939
239 #ISO-2022-JP
240 #ISO-2022-JP-2
241 #ISO-2022-JP-3
242 #ISO-2022-KR
243 #ISO-2022-CN
244 #ISO-2022-CN-EXT
245 #UTF-7
248 while read charset charmap; do
249 if test "$charset" = GB18030; then echo "This might take a while" 1>&2; fi
250 case ${charset} in \#*) continue;; esac
251 echo -n "Testing ${charset}" 1>&2
252 if ${SHELL} tst-table.sh ${common_objpfx} ${objpfx} ${charset} ${charmap}; then
253 echo 1>&2
254 else
255 echo "failed: ./tst-table.sh ${common_objpfx} ${objpfx} ${charset} ${charmap}"
256 echo " *** FAILED ***" 1>&2
257 exit 1
259 done
261 exit $?