aboutsummaryrefslogtreecommitdiff
path: root/libX11/nls/Makefile.am
blob: 4c7f5779773f57b06c83801e2adcb60829223d0f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
x11localedir = $(X11_LOCALEDATADIR)
specdir = $(docdir)/Compose

include $(top_srcdir)/specs/xmlrules.in

EXTRA_DIST = locale.alias.pre compose.dir.pre locale.dir.pre \
	compose-check.pl compose-chart.pl

x11locale_DATA = locale.alias locale.dir compose.dir

CLEANFILES += \
	locale.alias locale.alias.l1 locale.alias.l2 \
	compose.dir compose.dir.l1 compose.dir.l2 \
	locale.dir locale.dir.l1 locale.dir.l2 \
	XLC_LOCALE

locales = \
	am_ET.UTF-8		\
	armscii-8		\
	C			\
	el_GR.UTF-8		\
	en_US.UTF-8		\
	fi_FI.UTF-8		\
	georgian-academy	\
	georgian-ps		\
	ibm-cp1133		\
	iscii-dev		\
	isiri-3342		\
	iso8859-1		\
	iso8859-10		\
	iso8859-11		\
	iso8859-13		\
	iso8859-14		\
	iso8859-15		\
	iso8859-2		\
	iso8859-3		\
	iso8859-4		\
	iso8859-5		\
	iso8859-6		\
	iso8859-7		\
	iso8859-8		\
	iso8859-9		\
	iso8859-9e		\
	ja			\
	ja.JIS			\
	ja_JP.UTF-8		\
	ja.S90			\
	ja.SJIS			\
	ja.U90			\
	ko			\
	koi8-c			\
	koi8-r			\
	koi8-u			\
	ko_KR.UTF-8		\
	microsoft-cp1251	\
	microsoft-cp1255	\
	microsoft-cp1256	\
	mulelao-1		\
	nokhchi-1		\
	pt_BR.UTF-8		\
	ru_RU.UTF-8		\
	tatar-cyr		\
	th_TH			\
	th_TH.UTF-8		\
	tscii-0			\
	vi_VN.tcvn		\
	vi_VN.viscii		\
	zh_CN			\
	zh_CN.gb18030		\
	zh_CN.gbk		\
	zh_CN.UTF-8		\
	zh_HK.big5		\
	zh_HK.big5hkscs		\
	zh_HK.UTF-8		\
	zh_TW			\
	zh_TW.big5		\
	zh_TW.UTF-8

include $(top_srcdir)/cpprules.in

# Global data files

locale.alias: locale.alias.pre
	$(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $(srcdir)/locale.alias.pre | $(CPP_SED_MAGIC) > locale.alias.l1
	sed -e '/^[^#][^        ]*:/s/://' -e '/^[^#].*[        ].*:/d' \
        < locale.alias.l1 > locale.alias.l2
	cat locale.alias.l2 locale.alias.l1 > locale.alias

compose.dir: compose.dir.pre
	$(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $(srcdir)/compose.dir.pre | $(CPP_SED_MAGIC) > compose.dir.l1
	sed -e '/^[^#][^        ]*:/s/://' -e '/^[^#].*[        ].*:/d' \
        < compose.dir.l1 > compose.dir.l2
	cat compose.dir.l2 compose.dir.l1 > compose.dir

locale.dir: locale.dir.pre
	$(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $(srcdir)/locale.dir.pre | $(CPP_SED_MAGIC) > locale.dir.l1
	sed -e '/^[^#][^        ]*:/s/://' -e '/^[^#].*[        ].*:/d' \
        < locale.dir.l1 > locale.dir.l2
	cat locale.dir.l2 locale.dir.l1 > locale.dir

if HAVE_PERL
doc_sources = Compose/index.xml

Compose/index.xml: Compose
	$(AM_V_GEN)$(PERL) $(srcdir)/compose-chart.pl \
	 --index --output="$@" $(locales)

Compose:
	$(MKDIR_P) $@

clean-local: clean-Compose-dir
clean-Compose-dir:
	-rm -rf Compose
endif HAVE_PERL


# Per-locale data files

nobase_dist_x11locale_DATA = $(locales:%=%/XI18N_OBJS)

nobase_x11locale_DATA = $(locales:%=%/XLC_LOCALE) $(locales:%=%/Compose)
EXTRA_DIST += $(nobase_x11locale_DATA:%=%.pre)
CLEANFILES += $(nobase_x11locale_DATA)

$(nobase_x11locale_DATA): builddirs

builddirs:
	$(MKDIR_P) $(locales)

if HAVE_PERL
TESTS_ENVIRONMENT = $(PERL)
TESTS = $(srcdir)/compose-check.pl

COMPOSE_CHARTS = $(locales:%=%/Compose.xml)
doc_sources += $(locales:%=Compose/%.xml)
CLEANFILES += $(COMPOSE_CHARTS) $(doc_sources)

XMLTO_FLAGS += -o $(@D)

%/Compose.xml: %/Compose
	$(AM_V_GEN)$(PERL) $(srcdir)/compose-chart.pl \
	 --locale="$(@D)" --output="$@" $<

Compose/%.xml: %/Compose.xml
	$(AM_V_GEN)cp $< $@

$(doc_sources): Compose

endif HAVE_PERL