removed old libs
[TestXSLT.git] / libiconv / tools / Makefile
1
2 # Directory containing conversion tables.
3 # You have to unpack the conversion-tables.tar.gz package.
4 TABLESDIR = /home/bruno/chs/conversion-tables
5
6 ALL = \
7  ascii.h \
8  iso8859_1.h \
9  iso8859_2.h \
10  iso8859_3.h \
11  iso8859_4.h \
12  iso8859_5.h \
13  iso8859_6.h \
14  iso8859_7.h \
15  iso8859_8.h \
16  iso8859_9.h \
17  iso8859_10.h \
18  iso8859_13.h \
19  iso8859_14.h \
20  iso8859_15.h \
21  iso8859_16.h \
22  koi8_r.h \
23  koi8_u.h \
24  koi8_ru.h \
25  cp1250.h \
26  cp1251.h \
27  cp1252.h \
28  cp1253.h \
29  cp1254.h \
30  cp1255.h \
31  cp1256.h \
32  cp1257.h \
33  cp1258.h \
34  cp850.h \
35  cp862.h \
36  cp866.h \
37  mac_roman.h \
38  mac_centraleurope.h \
39  mac_iceland.h \
40  mac_croatian.h \
41  mac_romania.h \
42  mac_cyrillic.h \
43  mac_ukraine.h \
44  mac_greek.h \
45  mac_turkish.h \
46  mac_hebrew.h \
47  mac_arabic.h \
48  mac_thai.h \
49  hp_roman8.h \
50  nextstep.h \
51  armscii_8.h \
52  georgian_academy.h \
53  georgian_ps.h \
54  koi8_t.h \
55  mulelao.h \
56  cp1133.h \
57  tis620.h \
58  cp874.h \
59  viscii.h \
60  tcvn.h \
61  jisx0201.h \
62  jisx0208.h \
63  jisx0212.h \
64  cp932ext.h \
65  gb2312.h \
66  isoir165ext.h \
67  gb12345ext.h \
68  gbkext1.h \
69  gbkext2.h \
70  gbkext_inv.h \
71  cp936ext.h \
72  gb18030ext.h \
73  gb18030uni.h \
74  cns11643_1.h \
75  cns11643_2.h \
76  cns11643_3.h \
77  cns11643_4a.h \
78  cns11643_4b.h \
79  cns11643_5.h \
80  cns11643_6.h \
81  cns11643_7.h \
82  cns11643_15.h \
83  cns11643_inv.h \
84  big5.h \
85  cp950ext.h \
86  hkscs.h \
87  ksc5601.h \
88  uhc_1.h \
89  uhc_2.h \
90  johab_hangul.h \
91  cp856.h \
92  cp922.h \
93  cp1046.h \
94  cp1124.h \
95  cp1129.h \
96  cp1161.h \
97  cp1162.h \
98  cp1163.h \
99  cp437.h \
100  cp737.h \
101  cp775.h \
102  cp852.h \
103  cp853.h \
104  cp855.h \
105  cp857.h \
106  cp858.h \
107  cp860.h \
108  cp861.h \
109  cp863.h \
110  cp864.h \
111  cp865.h \
112  cp869.h \
113  cp1125.h \
114  jisx0213.h \
115  tds565.h \
116  riscos1.h \
117  cjk_variants.h
118
119 all : $(ALL)
120
121 ascii.h : $(TABLESDIR)/glibc-2.1-iconv/ASCII.TXT 8bit_tab_to_h
122         ./8bit_tab_to_h ASCII ascii < $<
123
124 iso8859_1.h : $(TABLESDIR)/unicode.org-mappings/ISO8859/8859-1.TXT 8bit_tab_to_h
125         ./8bit_tab_to_h ISO-8859-1 iso8859_1 < $<
126
127 iso8859_2.h : $(TABLESDIR)/unicode.org-mappings/ISO8859/8859-2.TXT 8bit_tab_to_h
128         ./8bit_tab_to_h ISO-8859-2 iso8859_2 < $<
129
130 iso8859_3.h : $(TABLESDIR)/unicode.org-mappings/ISO8859/8859-3.TXT 8bit_tab_to_h
131         ./8bit_tab_to_h ISO-8859-3 iso8859_3 < $<
132
133 iso8859_4.h : $(TABLESDIR)/unicode.org-mappings/ISO8859/8859-4.TXT 8bit_tab_to_h
134         ./8bit_tab_to_h ISO-8859-4 iso8859_4 < $<
135
136 iso8859_5.h : $(TABLESDIR)/unicode.org-mappings/ISO8859/8859-5.TXT 8bit_tab_to_h
137         ./8bit_tab_to_h ISO-8859-5 iso8859_5 < $<
138
139 iso8859_6.h : $(TABLESDIR)/unicode.org-mappings/ISO8859/8859-6.TXT 8bit_tab_to_h
140         ./8bit_tab_to_h ISO-8859-6 iso8859_6 < $<
141
142 iso8859_7.h : $(TABLESDIR)/unicode.org-mappings/ISO8859/8859-7.TXT 8bit_tab_to_h
143         ./8bit_tab_to_h ISO-8859-7 iso8859_7 < $<
144
145 iso8859_8.h : $(TABLESDIR)/unicode.org-mappings/ISO8859/8859-8.TXT 8bit_tab_to_h
146         ./8bit_tab_to_h ISO-8859-8 iso8859_8 < $<
147
148 iso8859_9.h : $(TABLESDIR)/unicode.org-mappings/ISO8859/8859-9.TXT 8bit_tab_to_h
149         ./8bit_tab_to_h ISO-8859-9 iso8859_9 < $<
150
151 iso8859_10.h : $(TABLESDIR)/unicode.org-mappings/ISO8859/8859-10.TXT 8bit_tab_to_h
152         ./8bit_tab_to_h ISO-8859-10 iso8859_10 < $<
153
154 iso8859_13.h : $(TABLESDIR)/unicode.org-mappings/ISO8859/8859-13.TXT 8bit_tab_to_h
155         ./8bit_tab_to_h ISO-8859-13 iso8859_13 < $<
156
157 iso8859_14.h : $(TABLESDIR)/unicode.org-mappings/ISO8859/8859-14.TXT 8bit_tab_to_h
158         ./8bit_tab_to_h ISO-8859-14 iso8859_14 < $<
159
160 iso8859_15.h : $(TABLESDIR)/unicode.org-mappings/ISO8859/8859-15.TXT 8bit_tab_to_h
161         ./8bit_tab_to_h ISO-8859-15 iso8859_15 < $<
162
163 iso8859_16.h : $(TABLESDIR)/unicode.org-mappings/ISO8859/8859-16.TXT 8bit_tab_to_h
164         ./8bit_tab_to_h ISO-8859-16 iso8859_16 < $<
165
166 koi8_r.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MISC/KOI8-R.TXT 8bit_tab_to_h
167         ./8bit_tab_to_h KOI8-R koi8_r < $<
168
169 koi8_u.h : $(TABLESDIR)/csets-new/KOI8-U.TXT 8bit_tab_to_h
170         ./8bit_tab_to_h KOI8-U koi8_u < $<
171
172 koi8_ru.h : $(TABLESDIR)/freebsd-iconv-0.4/KOI8-RU.TXT 8bit_tab_to_h
173         ./8bit_tab_to_h KOI8-RU koi8_ru < $<
174
175 cp1250.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/WINDOWS/CP1250.TXT 8bit_tab_to_h
176         ./8bit_tab_to_h CP1250 cp1250 < $<
177
178 cp1251.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/WINDOWS/CP1251.TXT 8bit_tab_to_h
179         ./8bit_tab_to_h CP1251 cp1251 < $<
180
181 cp1252.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/WINDOWS/CP1252.TXT 8bit_tab_to_h
182         ./8bit_tab_to_h CP1252 cp1252 < $<
183
184 cp1253.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/WINDOWS/CP1253.TXT 8bit_tab_to_h
185         ./8bit_tab_to_h CP1253 cp1253 < $<
186
187 cp1254.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/WINDOWS/CP1254.TXT 8bit_tab_to_h
188         ./8bit_tab_to_h CP1254 cp1254 < $<
189
190 cp1255.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/WINDOWS/CP1255.TXT 8bit_tab_to_h
191         ./8bit_tab_to_h CP1255 cp1255 < $<
192
193 cp1256.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/WINDOWS/CP1256.TXT 8bit_tab_to_h
194         ./8bit_tab_to_h CP1256 cp1256 < $<
195
196 cp1257.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/WINDOWS/CP1257.TXT 8bit_tab_to_h
197         ./8bit_tab_to_h CP1257 cp1257 < $<
198
199 cp1258.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/WINDOWS/CP1258.TXT 8bit_tab_to_h
200         ./8bit_tab_to_h CP1258 cp1258 < $<
201
202 cp850.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/PC/CP850.TXT 8bit_tab_to_h
203         ./8bit_tab_to_h CP850 cp850 < $<
204
205 cp862.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/PC/CP862.TXT 8bit_tab_to_h
206         ./8bit_tab_to_h CP862 cp862 < $<
207
208 cp866.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/PC/CP866.TXT 8bit_tab_to_h
209         ./8bit_tab_to_h CP866 cp866 < $<
210
211 mac_roman.h : $(TABLESDIR)/jdk-1.1.7b/MAC-ROMAN.TXT 8bit_tab_to_h
212         ./8bit_tab_to_h MacRoman mac_roman < $<
213
214 mac_centraleurope.h : $(TABLESDIR)/jdk-1.1.7b/MAC-CENTRAL-EUROPE.TXT 8bit_tab_to_h
215         ./8bit_tab_to_h MacCentralEurope mac_centraleurope < $<
216
217 mac_iceland.h : $(TABLESDIR)/jdk-1.1.7b/MAC-ICELAND.TXT 8bit_tab_to_h
218         ./8bit_tab_to_h MacIceland mac_iceland < $<
219
220 mac_croatian.h : $(TABLESDIR)/jdk-1.1.7b/MAC-CROATIAN.TXT 8bit_tab_to_h
221         ./8bit_tab_to_h MacCroatian mac_croatian < $<
222
223 mac_romania.h : $(TABLESDIR)/jdk-1.1.7b/MAC-ROMANIA.TXT 8bit_tab_to_h
224         ./8bit_tab_to_h MacRomania mac_romania < $<
225
226 mac_cyrillic.h : $(TABLESDIR)/jdk-1.1.7b/MAC-CYRILLIC.TXT 8bit_tab_to_h
227         ./8bit_tab_to_h MacCyrillic mac_cyrillic < $<
228
229 mac_ukraine.h : $(TABLESDIR)/jdk-1.1.7b/MAC-UKRAINE.TXT 8bit_tab_to_h
230         ./8bit_tab_to_h MacUkraine mac_ukraine < $<
231
232 mac_greek.h : $(TABLESDIR)/jdk-1.1.7b/MAC-GREEK.TXT 8bit_tab_to_h
233         ./8bit_tab_to_h MacGreek mac_greek < $<
234
235 mac_turkish.h : $(TABLESDIR)/jdk-1.1.7b/MAC-TURKISH.TXT 8bit_tab_to_h
236         ./8bit_tab_to_h MacTurkish mac_turkish < $<
237
238 mac_hebrew.h : $(TABLESDIR)/jdk-1.1.7b/MAC-HEBREW.TXT 8bit_tab_to_h
239         ./8bit_tab_to_h MacHebrew mac_hebrew < $<
240
241 mac_arabic.h : $(TABLESDIR)/jdk-1.1.7b/MAC-ARABIC.TXT 8bit_tab_to_h
242         ./8bit_tab_to_h MacArabic mac_arabic < $<
243
244 mac_thai.h : $(TABLESDIR)/jdk-1.1.7b/MAC-THAI.TXT 8bit_tab_to_h
245         ./8bit_tab_to_h MacThai mac_thai < $<
246
247 hp_roman8.h : $(TABLESDIR)/glibc-2.1-iconv/HP-ROMAN8.TXT 8bit_tab_to_h
248         ./8bit_tab_to_h HP-ROMAN8 hp_roman8 < $<
249
250 nextstep.h : $(TABLESDIR)/clisp/NEXTSTEP.TXT 8bit_tab_to_h
251         ./8bit_tab_to_h NEXTSTEP nextstep < $<
252
253 armscii_8.h : $(TABLESDIR)/glibc-2.2.90-iconv/ARMSCII-8.TXT 8bit_tab_to_h
254         (echo '#' ; cat $<) | ./8bit_tab_to_h ARMSCII-8 armscii_8
255
256 georgian_academy.h : $(TABLESDIR)/csets-1.6/GEO-ITA.TXT 8bit_tab_to_h
257         ./8bit_tab_to_h GEORGIAN-ACADEMY georgian_academy < $<
258
259 georgian_ps.h : $(TABLESDIR)/csets-1.6/GEO-PS.TXT 8bit_tab_to_h
260         ./8bit_tab_to_h GEORGIAN-PS georgian_ps < $<
261
262 koi8_t.h : $(TABLESDIR)/glibc-2.2.90-iconv/KOI8-T.TXT
263         (echo '#' ; cat $<) | ./8bit_tab_to_h KOI8-T koi8_t
264
265 mulelao.h : $(TABLESDIR)/csets-new/MULELAO1.TXT 8bit_tab_to_h
266         ./8bit_tab_to_h MULELAO-1 mulelao < $<
267
268 cp1133.h : $(TABLESDIR)/csets-new/CP1133.TXT 8bit_tab_to_h
269         ./8bit_tab_to_h IBM-CP1133 cp1133 < $<
270
271 tis620.h : $(TABLESDIR)/glibc-2.1-iconv/TIS-620.TXT 8bit_tab_to_h
272         ./8bit_tab_to_h TIS620.2533-1 tis620 < $<
273
274 cp874.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/WINDOWS/CP874.TXT 8bit_tab_to_h
275         ./8bit_tab_to_h CP874 cp874 < $<
276
277 viscii.h : $(TABLESDIR)/csets-1.6/VISCII.TXT 8bit_tab_to_h
278         ./8bit_tab_to_h VISCII1.1-1 viscii < $<
279
280 tcvn.h : $(TABLESDIR)/csets-1.6/VN5712-1.TXT 8bit_tab_to_h
281         ./8bit_tab_to_h TCVN-5712 tcvn < $<
282
283 jisx0201.h : $(TABLESDIR)/clisp/JIS_X0201.TXT 8bit_tab_to_h
284         ./8bit_tab_to_h JISX0201.1976-0 jisx0201 < $<
285
286 # We use modified JISX0208 and JISX0212 tables. Why?
287 # Hironori Sakamoto and Tomohiro Kubota explain that
288 # - EUC-JP and SHIFT_JIS contain JISX0208 exactly,
289 # - Their round-trip conversion to Unicode and back must be the identity,
290 # - Conversions between EUC-JP, SHIFT_JIS, CP932, ISO-2022-JP must behave
291 #   as if no Unicode conversion was involved,
292 # - When JISX0208 is used as a CES (i.e. combined with ASCII) its mapping of
293 #   REVERSE SOLIDUS becomes a FULLWIDTH REVERSE SOLIDUS, apparently because
294 #   round-trip conversion stability is more important than a particular glyph.
295 #   Only with CCS the character is a REVERSE SOLIDUS.
296 # As a consequence, we use FULLWIDTH REVERSE SOLIDUS in EUC-JP's JISX0208 part,
297 # and for consistency also in SHIFT_JIS and ISO-2022-JP, i.e. everywhere.
298 # JISX0208 never occurs as a CCS in practice. Similarly with JISX0212.
299
300 # Unicode.org maps 0x2140 to U+005C. We map it to U+FF3C.
301 jisx0208.h : $(TABLESDIR)/unicode.org-mappings/EASTASIA/JIS/JIS0208.TXT cjk_tab_to_h
302         sed -e 's,^0x....[      ]*\(0x....[     ]*0x.....*\)$$,\1,' < $< | sed -e 's,\([        ]\)0x005C,\10xFF3C,' | ./cjk_tab_to_h JISX0208.1990-0 jisx0208 > $@
303
304 # Unicode.org maps 0x2237 to U+007E. We map it to U+FF5E.
305 jisx0212.h : $(TABLESDIR)/unicode.org-mappings/EASTASIA/JIS/JIS0212.TXT cjk_tab_to_h
306         sed -e 's,\([   ]\)0x007E,\10xFF5E,' < $< | ./cjk_tab_to_h JISX0212.1990-0 jisx0212 > $@
307
308 cp932ext.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/WINDOWS/CP932.TXT cjk_tab_to_h
309         (echo '#' ; grep '^0x\(87\|E[D-F]\|F[0-9A-F]\)[0-9A-F][0-9A-F]' < $< ) | ./cjk_tab_to_h 'CP932 extensions' cp932ext > $@
310
311 gb2312.h : $(TABLESDIR)/unicode.org-mappings/EASTASIA/GB/GB2312.TXT cjk_tab_to_h
312         ./cjk_tab_to_h GB2312.1980-0 gb2312 < $< > $@
313
314 isoir165ext.h : $(TABLESDIR)/csets-new/ISO-IR-165-additions.TXT cjk_tab_to_h
315         (echo '#' ; grep -v '^0x2[8A]' < $<) | ./cjk_tab_to_h 'ISO-IR-165 extensions' isoir165ext > $@
316
317 gb12345ext.h : $(TABLESDIR)/unicode.org-mappings/EASTASIA/GB/GB2312.TXT $(TABLESDIR)/unicode.org-mappings/EASTASIA/GB/GB12345-FIXED.TXT $(TABLESDIR)/csets-new/GB12345-more.TXT cjk_tab_to_h
318         (echo '#' ; sed -e '/^0x..[     ]*#UNDEFINED/d' -e 's/#.*$$//' -e '/^[  ]*$$/d' $(TABLESDIR)/unicode.org-mappings/EASTASIA/GB/GB2312.TXT > tmp1.TXT ; sed -e '/^0x..[   ]*#UNDEFINED/d' -e 's/#.*$$//' -e '/^[  ]*$$/d' $(TABLESDIR)/unicode.org-mappings/EASTASIA/GB/GB12345-FIXED.TXT > tmp2.TXT ; diff tmp1.TXT tmp2.TXT | grep '^> ' | sed -e 's,^> ,,' ; cat $(TABLESDIR)/csets-new/GB12345-more.TXT ) | ./cjk_tab_to_h 'GB/T 12345.1990-0 extensions' gb12345ext > $@ && rm -f tmp1.TXT tmp2.TXT
319
320 gbkext1.h : GBKext.TXT cjk_tab_to_h
321         (echo '#' ; grep '^0x\([89].\|A0\)' < GBKext.TXT) | ./cjk_tab_to_h 'GBK/3 extensions' gbkext1 > $@
322
323 gbkext2.h : GBKext.TXT cjk_tab_to_h
324         (echo '#' ; grep '^0x\(A[1-9A-F]\|[B-F][0-9A-F]\)\([4-9].\|A0\)' < GBKext.TXT) | ./cjk_tab_to_h 'GBK/4 and GBK/5 extensions' gbkext2 > $@
325
326 gbkext_inv.h : GBKext.TXT cjk_tab_to_h
327         (echo '#' ; grep '^0x\([89].\|A0\)' < GBKext.TXT ; grep '^0x\(A[1-9A-F]\|[B-F][0-9A-F]\)\([4-9].\|A0\)' < GBKext.TXT) | ./cjk_tab_to_h 'GBK extensions' gbkext_inv > $@
328
329 cp936ext.h : GBKext.TXT cjk_tab_to_h
330         (echo '#' ; grep '^0xA[1-9][B-F].' < GBKext.TXT) | ./cjk_tab_to_h 'CP936 extensions' cp936ext > $@
331
332 GBKext.TXT : $(TABLESDIR)/unicode.org-mappings/EASTASIA/GB/GB2312.TXT $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/WINDOWS/CP936.TXT
333         sed -e 's,^0x2,0xA,' -e 's,^0x3,0xB,' -e 's,^0x4,0xC,' -e 's,^0x5,0xD,' -e 's,^0x6,0xE,' -e 's,^0x7,0xF,' -e 's,^0x\(..\)2,0x\1A,' -e 's,^0x\(..\)3,0x\1B,' -e 's,^0x\(..\)4,0x\1C,' -e 's,^0x\(..\)5,0x\1D,' -e 's,^0x\(..\)6,0x\1E,' -e 's,^0x\(..\)7,0x\1F,' $(TABLESDIR)/unicode.org-mappings/EASTASIA/GB/GB2312.TXT > tmpEUCCN.TXT ; sed -e '/^0x..[       ]*#UNDEFINED/d' -e 's/#.*$$//' -e '/^[  ]*$$/d' tmpEUCCN.TXT > tmp1.TXT ; sed -e '/^0x..[       ]/d' -e 's/#.*$$//' -e '/^[     ]*$$/d' $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/WINDOWS/CP936.TXT > tmp2.TXT ; diff -c1 tmp1.TXT tmp2.TXT | grep '^+ ' | sed -e 's,^+ ,,' > $@ && rm -f tmpEUCCN.TXT tmp1.TXT tmp2.TXT
334
335 gb18030ext.h : GB18030ext.TXT cjk_tab_to_h
336         (echo '#' ; cat GB18030ext.TXT) | ./cjk_tab_to_h 'GB18030 two-byte extension' gb18030ext > $@
337
338 GB18030ext.TXT : $(TABLESDIR)/glibc-2.2.2-iconv/GB18030.TXT $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/WINDOWS/CP936.TXT
339         cat $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/WINDOWS/CP936.TXT | sed -e 's/[    ]*#.*$$//' | grep '^0x[0-9A-F]* 0x....$$' > tmpGBK.TXT ; diff tmpGBK.TXT $(TABLESDIR)/glibc-2.2.2-iconv/GB18030.TXT | grep '^> 0x....   0x....$$' | sed -e 's/^> //' > $@ && rm -f tmpGBK.TXT
340
341 gb18030uni.h : GB18030uni.TXT cjk_tab_to_h
342         ./cjk_tab_to_h 'GB18030 four-byte extension' gb18030uni < GB18030uni.TXT > $@
343
344 GB18030uni.TXT : $(TABLESDIR)/gb18030/filled-GB18030.TXT
345         grep '^0x........       0x....$$' < $(TABLESDIR)/gb18030/filled-GB18030.TXT > $@
346
347 cns11643_1.h : $(TABLESDIR)/csets-new/CNS11643-Unicode32.TXT cjk_tab_to_h
348         grep '^\(#\|0x1\)' < $< | sed -e 's,^0x1,0x,' | ./cjk_tab_to_h 'CNS 11643-1992 plane 1' cns11643_1 > $@
349
350 cns11643_2.h : $(TABLESDIR)/csets-new/CNS11643-Unicode32.TXT cjk_tab_to_h
351         grep '^\(#\|0x2\)' < $< | sed -e 's,^0x2,0x,' | ./cjk_tab_to_h 'CNS 11643-1992 plane 2' cns11643_2 > $@
352
353 cns11643_3.h : $(TABLESDIR)/csets-new/CNS11643-Unicode32.TXT cjk_tab_to_h
354         grep '^\(#\|0x3\)' < $< | sed -e 's,^0x3,0x,' | ./cjk_tab_to_h 'CNS 11643-1992 plane 3' cns11643_3 > $@
355
356 cns11643_4a.h : $(TABLESDIR)/csets-new/CNS11643-Unicode32.TXT cjk_tab_to_h
357         grep '^\(#\|0x4[0-3]\)' < $< | sed -e 's,^0x4,0x,' | ./cjk_tab_to_h 'CNS 11643-1992 plane 4 part a' cns11643_4a > $@
358
359 cns11643_4b.h : $(TABLESDIR)/csets-new/CNS11643-Unicode32.TXT cjk_tab_to_h
360         grep '^\(#\|0x4[4-7]\)' < $< | sed -e 's,^0x4,0x,' | ./cjk_tab_to_h 'CNS 11643-1992 plane 4 part b' cns11643_4b > $@
361
362 cns11643_5.h : $(TABLESDIR)/csets-new/CNS11643-Unicode32.TXT cjk_tab_to_h
363         grep '^\(#\|0x5\)' < $< | sed -e 's,^0x5,0x,' | ./cjk_tab_to_h 'CNS 11643-1992 plane 5' cns11643_5 > $@
364
365 cns11643_6.h : $(TABLESDIR)/csets-new/CNS11643-Unicode32.TXT cjk_tab_to_h
366         grep '^\(#\|0x6\)' < $< | sed -e 's,^0x6,0x,' | ./cjk_tab_to_h 'CNS 11643-1992 plane 6' cns11643_6 > $@
367
368 cns11643_7.h : $(TABLESDIR)/csets-new/CNS11643-Unicode32.TXT cjk_tab_to_h
369         grep '^\(#\|0x7\)' < $< | sed -e 's,^0x7,0x,' | ./cjk_tab_to_h 'CNS 11643-1992 plane 7' cns11643_7 > $@
370
371 cns11643_15.h : $(TABLESDIR)/csets-new/CNS11643-Unicode32.TXT cjk_tab_to_h
372         grep '^\(#\|0xF\)' < $< | sed -e 's,^0xF,0x,' | ./cjk_tab_to_h 'CNS 11643-1992 plane 15' cns11643_15 > $@
373
374 cns11643_inv.h : $(TABLESDIR)/csets-new/CNS11643-Unicode32.TXT cjk_tab_to_h
375         ./cjk_tab_to_h 'CNS 11643-1992 planes 1-7, CNS 11643-1986 plane 15' cns11643_inv < $< > $@
376
377 big5.h : $(TABLESDIR)/unicode.org-mappings/EASTASIA/OTHER/BIG5.TXT cjk_tab_to_h
378         ./cjk_tab_to_h BIG5 big5 < $< > $@
379
380 cp950ext.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/WINDOWS/CP950.TXT cjk_tab_to_h
381         (echo '#' ; grep '^0xF9\(D[6-9A-F]\|[EF][0-9A-F]\)' < $< ) | ./cjk_tab_to_h 'CP950 extensions' cp950ext > $@
382
383 hkscs.h : $(TABLESDIR)/big5hkscs/HKSCS.TXT cjk_tab_to_h
384         (echo '#' ; cat $<) | ./cjk_tab_to_h HKSCS hkscs > $@
385
386 # We use a modified KSC 5601 = KSX 1001 table. Jungshik Shin <jshin@mailaps.org>
387 # reports that Prof. GIM Geongseog (KIM Keyongseok) <gimgs@asadal.cs.pusan.ac.kr>
388 # (who represents South Korea in ISO/IEC JTC1 SC2/WG2 and SC22/WG20) says that
389 # these two characters were added to KSX 1001 in December 1998, and one more
390 # (Korean zip code sign) is likely to follow in 2002.
391 ksc5601.h : $(TABLESDIR)/unicode.org-mappings/EASTASIA/KSC/KSC5601.TXT cjk_tab_to_h
392         (cat $< ; echo '0xA2E6  0x20AC'; echo '0xA2E7   0x00AE') | ./cjk_tab_to_h KSC5601.1987-0 ksc5601 > $@
393
394 uhc_1.h : $(TABLESDIR)/unicode.org-mappings/EASTASIA/KSC/KSC5601.TXT cjk_tab_to_h
395         (echo '#' ; grep '^0x\([8-9]\|A0\)' < $< ) | ./cjk_tab_to_h 'Unified Hangul Code part 1' uhc_1 > $@
396
397 uhc_2.h : $(TABLESDIR)/unicode.org-mappings/EASTASIA/KSC/KSC5601.TXT cjk_tab_to_h
398         (echo '#' ; grep '^0x\(A[1-9A-F]\|[B-F][0-9A-F]\)\([0-9]\|A0\)' < $< ) | ./cjk_tab_to_h 'Unified Hangul Code part 2' uhc_2 > $@
399
400 johab_hangul.h : $(TABLESDIR)/unicode.org-mappings/EASTASIA/KSC/JOHAB.TXT cjk_tab_to_h
401         (echo '#' ; grep '^0x\([8-C]...\|D[0-7]..\)' < $< ) | ./cjk_tab_to_h 'JOHAB Hangul' johab_hangul > $@
402
403
404 cp856.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MISC/CP856.TXT 8bit_tab_to_h
405         ./8bit_tab_to_h CP856 cp856 < $<
406
407 cp922.h : $(TABLESDIR)/aix-4.3.2/IBM-922.TXT 8bit_tab_to_h
408         (echo '#' ; cat $<) | ./8bit_tab_to_h CP922 cp922
409
410 cp1046.h : $(TABLESDIR)/aix-4.3.2/IBM-1046.TXT 8bit_tab_to_h
411         (echo '#' ; cat $<) | ./8bit_tab_to_h CP1046 cp1046
412
413 cp1124.h : $(TABLESDIR)/aix-4.3.2/IBM-1124.TXT 8bit_tab_to_h
414         (echo '#' ; cat $<) | ./8bit_tab_to_h CP1124 cp1124
415
416 cp1129.h : $(TABLESDIR)/aix-4.3.2/IBM-1129.TXT 8bit_tab_to_h
417         (echo '#' ; cat $<) | ./8bit_tab_to_h CP1129 cp1129
418
419 cp1161.h : $(TABLESDIR)/glibc-2.2.90-iconv/IBM1161.TXT
420         (echo '#' ; cat $(TABLESDIR)/glibc-2.2-iconv/ASCII.TXT ; grep -v '^0x[0-7]' $<) | ./8bit_tab_to_h CP1161 cp1161
421
422 cp1162.h : $(TABLESDIR)/glibc-2.2.90-iconv/IBM1162.TXT
423         (echo '#' ; cat $<) | ./8bit_tab_to_h CP1162 cp1162
424
425 cp1163.h : $(TABLESDIR)/glibc-2.2.90-iconv/IBM1163.TXT
426         (echo '#' ; cat $<) | ./8bit_tab_to_h CP1163 cp1163
427
428
429 cp437.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/PC/CP437.TXT 8bit_tab_to_h
430         ./8bit_tab_to_h CP437 cp437 < $<
431
432 cp737.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/PC/CP737.TXT 8bit_tab_to_h
433         ./8bit_tab_to_h CP737 cp737 < $<
434
435 cp775.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/PC/CP775.TXT 8bit_tab_to_h
436         ./8bit_tab_to_h CP775 cp775 < $<
437
438 cp852.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/PC/CP852.TXT 8bit_tab_to_h
439         ./8bit_tab_to_h CP852 cp852 < $<
440
441 cp853.h : $(TABLESDIR)/other/CP853.TXT 8bit_tab_to_h
442         (echo '#'; cat $<) | ./8bit_tab_to_h CP853 cp853
443
444 cp855.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/PC/CP855.TXT 8bit_tab_to_h
445         ./8bit_tab_to_h CP855 cp855 < $<
446
447 cp857.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/PC/CP857.TXT 8bit_tab_to_h
448         ./8bit_tab_to_h CP857 cp857 < $<
449
450 cp858.h : $(TABLESDIR)/windows-2000/CP858.TXT 8bit_tab_to_h
451         (echo '#' ; cat $<) | ./8bit_tab_to_h CP858 cp858
452
453 cp860.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/PC/CP860.TXT 8bit_tab_to_h
454         ./8bit_tab_to_h CP860 cp860 < $<
455
456 cp861.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/PC/CP861.TXT 8bit_tab_to_h
457         ./8bit_tab_to_h CP861 cp861 < $<
458
459 cp863.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/PC/CP863.TXT 8bit_tab_to_h
460         ./8bit_tab_to_h CP863 cp863 < $<
461
462 cp864.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/PC/CP864.TXT 8bit_tab_to_h
463         ./8bit_tab_to_h CP864 cp864 < $<
464
465 cp865.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/PC/CP865.TXT 8bit_tab_to_h
466         ./8bit_tab_to_h CP865 cp865 < $<
467
468 cp869.h : $(TABLESDIR)/unicode.org-mappings/VENDORS/MICSFT/PC/CP869.TXT 8bit_tab_to_h
469         ./8bit_tab_to_h CP869 cp869 < $<
470
471 cp1125.h : $(TABLESDIR)/csets-new/CP1125.TXT 8bit_tab_to_h
472         ./8bit_tab_to_h CP1125 cp1125 < $<
473
474
475 jisx0213.h : JISX0213.TXT cjk_tab_to_h
476         ./cjk_tab_to_h JISX0213:2000 jisx0213 < $< > $@
477
478 tds565.h : $(TABLESDIR)/recode-cvs/TDS565.TXT 8bit_tab_to_h
479         (echo '#'; cat $<) | ./8bit_tab_to_h TDS565 tds565 > $@
480
481 riscos1.h : $(TABLESDIR)/recode-cvs/RISCOS-LATIN1.TXT 8bit_tab_to_h
482         (echo '#'; cat $<) | ./8bit_tab_to_h RISCOS-LATIN1 riscos1 > $@
483
484
485 cjk_variants.h : $(TABLESDIR)/yasuoka/UniVariants cjk_variants
486         ./cjk_variants < $< > $@
487
488
489 8bit_tab_to_h : 8bit_tab_to_h.c
490         gcc -O -Wall -g $< -o $@
491
492 cjk_tab_to_h : cjk_tab_to_h.c
493         gcc -O -Wall -g $< -o $@
494
495 cjk_variants : cjk_variants.c
496         gcc -O -Wall -g $< -o $@
497
498
499 clean : force
500         rm -f 8bit_tab_to_h cjk_tab_to_h cjk_variants $(ALL) GBKext.TXT
501
502 force :
503