]>
Commit | Line | Data |
---|---|---|
b79f74cd | 1 | #!/bin/sh |
f7a9f785 | 2 | # Copyright (C) 2000-2016 Free Software Foundation, Inc. |
b79f74cd UD |
3 | # This file is part of the GNU C Library. |
4 | # Contributed by Bruno Haible <haible@clisp.cons.org>, 2000. | |
5 | # | |
41bdb6e2 | 6 | |
b79f74cd | 7 | # The GNU C Library is free software; you can redistribute it and/or |
41bdb6e2 AJ |
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. | |
11 | ||
b79f74cd UD |
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 | |
41bdb6e2 AJ |
15 | # Lesser General Public License for more details. |
16 | ||
17 | # You should have received a copy of the GNU Lesser General Public | |
59ba27a6 PE |
18 | # License along with the GNU C Library; if not, see |
19 | # <http://www.gnu.org/licenses/>. | |
b79f74cd UD |
20 | |
21 | # Checks that the iconv() implementation (in both directions) for the | |
22 | # stateless encodings agrees with the corresponding charmap table. | |
23 | ||
24 | common_objpfx=$1 | |
25 | objpfx=$2 | |
740b3dbe | 26 | test_program_prefix=$3 |
b79f74cd UD |
27 | |
28 | status=0 | |
29 | ||
30 | cat <<EOF | | |
31 | # Single-byte and other "small" encodings come here. | |
32 | # Keep this list in the same order as gconv-modules. | |
33 | # | |
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 | |
8ad5c3cd | 68 | ISO-8859-9E |
b79f74cd | 69 | ISO-8859-10 |
cb2a71bb | 70 | ISO-8859-11 |
b79f74cd UD |
71 | ISO-8859-13 |
72 | ISO-8859-14 | |
73 | ISO-8859-15 | |
74 | ISO-8859-16 | |
75 | T.61-8BIT | |
76 | ISO_6937 | |
77 | #ISO_6937-2 ISO-IR-90 Handling of combining marks is broken | |
78 | KOI-8 | |
79 | KOI8-R | |
80 | LATIN-GREEK | |
81 | LATIN-GREEK-1 | |
82 | HP-ROMAN8 | |
87520ccc | 83 | HP-ROMAN9 |
189dce4f UD |
84 | HP-TURKISH8 |
85 | HP-THAI8 | |
86 | HP-GREEK8 | |
b79f74cd UD |
87 | EBCDIC-AT-DE |
88 | EBCDIC-AT-DE-A | |
89 | EBCDIC-CA-FR | |
90 | EBCDIC-DK-NO | |
91 | EBCDIC-DK-NO-A | |
92 | EBCDIC-ES | |
93 | EBCDIC-ES-A | |
94 | EBCDIC-ES-S | |
95 | EBCDIC-FI-SE | |
96 | EBCDIC-FI-SE-A | |
97 | EBCDIC-FR | |
98 | EBCDIC-IS-FRISS | |
99 | EBCDIC-IT | |
100 | EBCDIC-PT | |
101 | EBCDIC-UK | |
102 | EBCDIC-US | |
103 | IBM037 | |
104 | IBM038 | |
105 | IBM256 | |
106 | IBM273 | |
107 | IBM274 | |
108 | IBM275 | |
109 | IBM277 | |
110 | IBM278 | |
111 | IBM280 | |
112 | IBM281 | |
113 | IBM284 | |
114 | IBM285 | |
115 | IBM290 | |
116 | IBM297 | |
117 | IBM420 | |
118 | IBM423 | |
119 | IBM424 | |
120 | IBM437 | |
121 | IBM500 | |
122 | IBM850 | |
123 | IBM851 | |
124 | IBM852 | |
125 | IBM855 | |
9813858f | 126 | IBM856 |
b79f74cd UD |
127 | IBM857 |
128 | IBM860 | |
129 | IBM861 | |
130 | IBM862 | |
131 | IBM863 | |
132 | IBM864 | |
133 | IBM865 | |
134 | IBM866 | |
2c255347 | 135 | IBM866NAV |
b79f74cd UD |
136 | IBM868 |
137 | IBM869 | |
138 | IBM870 | |
139 | IBM871 | |
140 | IBM875 | |
141 | IBM880 | |
142 | IBM891 | |
143 | IBM903 | |
144 | IBM904 | |
145 | IBM905 | |
146 | IBM918 | |
9813858f | 147 | IBM922 |
b79f74cd UD |
148 | IBM1004 |
149 | IBM1026 | |
9813858f | 150 | #IBM1046 Differs from the AIX and JDK converters |
b79f74cd | 151 | IBM1047 |
9813858f UD |
152 | IBM1124 |
153 | IBM1129 | |
154 | IBM1160 | |
155 | IBM1161 | |
156 | IBM1132 | |
157 | IBM1133 | |
158 | IBM1162 | |
159 | IBM1163 | |
160 | IBM1164 | |
b15c9395 | 161 | CP1125 |
b79f74cd UD |
162 | CP1250 |
163 | CP1251 | |
164 | CP1252 | |
165 | CP1253 | |
166 | CP1254 | |
167 | CP1255 | |
168 | CP1256 | |
169 | CP1257 | |
170 | CP1258 | |
171 | IBM874 | |
172 | CP737 | |
be97a69e UD |
173 | CP770 |
174 | CP771 | |
175 | CP772 | |
176 | CP773 | |
177 | CP774 | |
b79f74cd UD |
178 | CP775 |
179 | MACINTOSH | |
180 | IEC_P27-1 | |
181 | ASMO_449 | |
182 | ISO-IR-99 ANSI_X3.110-1983 | |
183 | ISO-IR-139 CSN_369103 | |
184 | CWI | |
185 | DEC-MCS | |
186 | ECMA-CYRILLIC | |
187 | ISO-IR-153 GOST_19768-74 | |
188 | GREEK-CCITT | |
189 | GREEK7 | |
190 | GREEK7-OLD | |
191 | INIS | |
192 | INIS-8 | |
193 | INIS-CYRILLIC | |
194 | ISO_2033 ISO_2033-1983 | |
195 | ISO_5427 | |
196 | ISO_5427-EXT | |
197 | #ISO_5428 Handling of combining marks is broken | |
198 | ISO_10367-BOX | |
199 | MAC-IS | |
200 | MAC-UK | |
65fa1dec | 201 | CP10007 |
b79f74cd UD |
202 | NATS-DANO |
203 | NATS-SEFI | |
204 | WIN-SAMI-2 SAMI-WS2 | |
205 | ISO-IR-197 | |
206 | TIS-620 | |
207 | KOI8-U | |
9813858f | 208 | #ISIRI-3342 This charset concept is completely broken |
6d5503b1 | 209 | VISCII |
9813858f | 210 | KOI8-T |
6906cea4 UD |
211 | GEORGIAN-PS |
212 | GEORGIAN-ACADEMY | |
9813858f UD |
213 | ISO-IR-209 |
214 | MAC-SAMI | |
215 | ARMSCII-8 | |
216 | TCVN5712-1 | |
fa00744e | 217 | TSCII |
7eb7fdda UD |
218 | PT154 |
219 | RK1048 | |
39450ec4 | 220 | MIK |
ddaafd04 | 221 | BRF |
27f3d446 | 222 | MAC-CENTRALEUROPE |
90bf831b | 223 | KOI8-RU |
b79f74cd UD |
224 | # |
225 | # Multibyte encodings come here | |
226 | # | |
aa64639e | 227 | SJIS SHIFT_JIS |
41d70e88 | 228 | CP932 WINDOWS-31J |
9813858f UD |
229 | #IBM932 This converter looks quite strange |
230 | #IBM943 This converter looks quite strange | |
1edd1b14 | 231 | EUC-KR |
b79f74cd | 232 | CP949 |
079e46f0 | 233 | JOHAB |
b79f74cd | 234 | BIG5 |
844fa825 | 235 | BIG5HKSCS BIG5-HKSCS |
b79f74cd | 236 | EUC-JP |
41d70e88 | 237 | EUC-JP-MS |
b79f74cd | 238 | EUC-CN GB2312 |
0b95971d | 239 | GBK |
b79f74cd | 240 | EUC-TW |
5de565cd | 241 | GB18030 |
93a568aa UD |
242 | EUC-JISX0213 |
243 | SHIFT_JISX0213 | |
b79f74cd UD |
244 | # |
245 | # Stateful encodings not testable this way | |
246 | # | |
9813858f UD |
247 | #IBM930 |
248 | #IBM933 | |
249 | #IBM935 | |
250 | #IBM937 | |
251 | #IBM939 | |
b79f74cd UD |
252 | #ISO-2022-JP |
253 | #ISO-2022-JP-2 | |
9bd64602 | 254 | #ISO-2022-JP-3 |
b79f74cd UD |
255 | #ISO-2022-KR |
256 | #ISO-2022-CN | |
bfc27ea4 | 257 | #ISO-2022-CN-EXT |
d6040f17 | 258 | #UTF-7 |
b79f74cd UD |
259 | # |
260 | EOF | |
261 | while read charset charmap; do | |
bfc27ea4 | 262 | if test "$charset" = GB18030; then echo "This might take a while" 1>&2; fi |
b79f74cd | 263 | case ${charset} in \#*) continue;; esac |
2c61c19f | 264 | printf %s "Testing ${charset}" 1>&2 |
740b3dbe | 265 | if ./tst-table.sh ${common_objpfx} ${objpfx} "${test_program_prefix}" \ |
6fb54a22 | 266 | ${charset} ${charmap} < /dev/null; then |
63e18f77 UD |
267 | echo 1>&2 |
268 | else | |
269 | echo "failed: ./tst-table.sh ${common_objpfx} ${objpfx} ${charset} ${charmap}" | |
270 | echo " *** FAILED ***" 1>&2 | |
271 | exit 1 | |
272 | fi | |
b79f74cd UD |
273 | done |
274 | ||
63e18f77 | 275 | exit $? |