xref: /freebsd/share/colldef/Makefile (revision 1e413cf93298b5b97441a21d9a50fdcd0ee9945e)
1# $FreeBSD$
2
3LOCALES=	bg_BG.CP1251 \
4		be_BY.CP1131 \
5		be_BY.CP1251 \
6		be_BY.ISO8859-5 \
7		ca_ES.ISO8859-1 \
8		ca_ES.ISO8859-15 \
9		cs_CZ.ISO8859-2 \
10		de_DE.ISO8859-1 \
11		de_DE.ISO8859-15 \
12		el_GR.ISO8859-7 \
13		es_ES.ISO8859-1 \
14		es_ES.ISO8859-15 \
15		et_EE.ISO8859-15 \
16		hi_IN.ISCII-DEV \
17		hy_AM.ARMSCII-8 \
18		is_IS.ISO8859-1 \
19		is_IS.ISO8859-15 \
20		kk_KZ.PT154 \
21		la_LN.ISO8859-1 \
22		la_LN.ISO8859-15 \
23		la_LN.ISO8859-2 \
24		la_LN.ISO8859-4 \
25		la_LN.US-ASCII \
26		lt_LT.ISO8859-4 \
27		lt_LT.ISO8859-13 \
28		pl_PL.ISO8859-2 \
29		ru_RU.CP1251 \
30		ru_RU.CP866 \
31		ru_RU.ISO8859-5 \
32		ru_RU.KOI8-R \
33		sl_SI.ISO8859-2 \
34		sr_YU.ISO8859-5 \
35		sv_SE.ISO8859-1 \
36		sv_SE.ISO8859-15 \
37		tr_TR.ISO8859-9 \
38		uk_UA.CP1251 \
39		uk_UA.ISO8859-5 \
40		uk_UA.KOI8-U
41
42LOCALEDIR=	/usr/share/locale
43
44.SUFFIXES: .src .out
45
46.src.out:
47	colldef -I ${.CURDIR} -o ${.TARGET} ${.IMPSRC}
48
49FILES=		${LOCALES:S/$/.out/}
50FILESNAME=	LC_COLLATE
51
52.for locale in ${LOCALES}
53FILESDIR_${locale}.out= ${LOCALEDIR}/${locale}
54.if exists(${.CURDIR}/map.${locale:E})
55${locale}.out: map.${locale:E}
56.endif
57.endfor
58
59CLEANFILES=	${FILES}
60
61ENCODINGS=	Big5 Big5HKSCS CP949 eucCN eucJP eucKR GB18030 GB2312 GBK \
62		ISO8859-1 ISO8859-2 ISO8859-15 SJIS US-ASCII UTF-8
63
64ISO8859-1_Big5=	is_IS:zh_TW
65ISO8859-1_ISO8859-1= ${ISO8859-15_ISO8859-15} pt_PT:pt_BR
66
67LATIN1LINKS=	af_ZA da_DK en_AU en_CA en_GB en_NZ en_US eu_ES fi_FI \
68		fr_BE fr_CA fr_CH fr_FR it_CH it_IT nb_NO nl_BE nl_NL \
69		nn_NO no_NO pt_PT
70ISO8859-15_ISO8859-15= de_DE:de_AT de_DE:de_CH ${LATIN1LINKS:C/^/la_LN:/}
71
72LATIN2LINKS=    hr_HR hu_HU ro_RO sr_YU
73ISO8859-2_ISO8859-2= ${LATIN2LINKS:C/^/la_LN:/} cs_CZ:sk_SK
74
75US-ASCII_Big5HKSCS= la_LN:zh_HK
76US-ASCII_CP949=	la_LN:ko_KR
77US-ASCII_eucCN=	la_LN:zh_CN
78US-ASCII_eucJP=	la_LN:ja_JP
79US-ASCII_eucKR=	la_LN:ko_KR
80US-ASCII_GB18030= la_LN:zh_CN
81US-ASCII_GB2312= la_LN:zh_CN
82US-ASCII_GBK=	la_LN:zh_CN
83US-ASCII_SJIS=	la_LN:ja_JP
84
85ASCIILINKS=	en_AU en_CA en_GB en_NZ en_US
86US-ASCII_US-ASCII= ${ASCIILINKS:C/^/la_LN:/}
87
88UTF8LINKS=	af_ZA am_ET be_BY bg_BG ca_ES cs_CZ da_DK de_AT de_CH \
89		de_DE el_GR en_AU en_CA en_GB en_IE en_NZ en_US es_ES \
90		et_EE eu_ES fi_FI fr_BE \
91		fr_CA fr_CH fr_FR he_IL hr_HR hu_HU hy_AM is_IS it_CH it_IT \
92		ja_JP kk_KZ ko_KR lt_LT mn_MN \
93		nb_NO nl_BE nl_NL nn_NO no_NO pl_PL pt_BR pt_PT \
94		ro_RO ru_RU sk_SK sl_SI sr_YU sv_SE tr_TR uk_UA zh_CN zh_HK \
95		zh_TW
96US-ASCII_UTF-8=	${UTF8LINKS:C/^/la_LN:/}
97
98SYMLINKS=
99.for enc1 in ${ENCODINGS}
100.for enc2 in ${ENCODINGS}
101.for lang_terr in ${${enc1}_${enc2}}
102SYMLINKS+=	../${lang_terr:C/:.*$//}.${enc1}/${FILESNAME} \
103		${LOCALEDIR}/${lang_terr:C/^.*://}.${enc2}
104.endfor
105.endfor
106.endfor
107
108.include <bsd.prog.mk>
109