(read_key_sequence): Fix typo.
[emacs.git] / leim / Makefile.in
blob14bcffb26fe91d1564c6f3858ef1a8d7db87bf88
1 # Makefile for leim subdirectory in GNU Emacs.
2 # Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
3 # Free Software Foundation, Inc.
4 # Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
5 # National Institute of Advanced Industrial Science and Technology (AIST)
6 # Registration Number H14PRO021
8 # This file is part of GNU Emacs.
10 # GNU Emacs is free software; you can redistribute it and/or modify
11 # it under the terms of the GNU General Public License as published by
12 # the Free Software Foundation; either version 3, or (at your option)
13 # any later version.
15 # GNU Emacs is distributed in the hope that it will be useful,
16 # but WITHOUT ANY WARRANTY; without even the implied warranty of
17 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 # GNU General Public License for more details.
20 # You should have received a copy of the GNU General Public License
21 # along with GNU Emacs; see the file COPYING. If not, write to the
22 # Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
23 # Boston, MA 02110-1301, USA.
25 # Avoid trouble on systems where the `SHELL' variable might be
26 # inherited from the environment.
27 SHELL = /bin/sh
29 # Here are the things that we expect ../configure to edit.
30 version=@version@
31 prefix=@prefix@
32 datarootdir=@datarootdir@
33 datadir=@datadir@
34 srcdir=@srcdir@
36 # Where to install LEIM files.
37 INSTALLDIR=$(DESTDIR)${datadir}/emacs/${version}/leim
39 GZIP_PROG = @GZIP_PROG@
41 # On Xenix and the IBM RS6000, double-dot gets screwed up.
42 dot = .
44 # Which Emacs to use to convert TIT files to Emacs Lisp files,
45 # byte-compile Emacs Lisp files, and generate the file leim-list.el.
46 BUILT-EMACS = ${dot}${dot}/src/emacs
48 buildlisppath=${srcdir}/${dot}${dot}/lisp
50 # How to run Emacs.
51 RUN-EMACS = EMACSLOADPATH=$(buildlisppath) LC_ALL=C\
52 ${BUILT-EMACS} -batch --no-init-file --no-site-file --multibyte
54 # Subdirectories to be made if ${srcdir} is different from the current
55 # directory.
56 SUBDIRS=quail
58 # Files generated from TIT dictionaries for Chinese GB character set.
59 TIT-GB=\
60 quail/CCDOSPY.elc \
61 quail/Punct.elc \
62 quail/QJ.elc \
63 quail/SW.elc \
64 quail/TONEPY.elc
66 # Files generated from TIT dictionaries for Chinese BIG5 character set.
67 TIT-BIG5=\
68 quail/4Corner.elc \
69 quail/ARRAY30.elc \
70 quail/ECDICT.elc \
71 quail/ETZY.elc \
72 quail/Punct-b5.elc \
73 quail/PY-b5.elc \
74 quail/QJ-b5.elc \
75 quail/ZOZY.elc
77 CHINESE-TIT=${TIT-GB} ${TIT-BIG5}
79 NON-TIT-GB=${srcdir}/quail/py-punct.elc
81 NON-TIT-BIG5=${srcdir}/quail/pypunct-b5.elc
83 CHINESE-NON-TIT=${NON-TIT-GB} ${NON-TIT-BIG5}
85 CHINESE-GB=${TIT-GB} ${NON-TIT-GB}
87 CHINESE-BIG5=${TIT-BIG5} ${NON-TIT-BIG5}
89 JAPANESE=${srcdir}/quail/japanese.elc ${srcdir}/ja-dic/ja-dic.elc
91 KOREAN= ${srcdir}/quail/hangul.elc \
92 ${srcdir}/quail/hangul3.elc \
93 ${srcdir}/quail/hanja.elc \
94 ${srcdir}/quail/hanja3.elc \
95 ${srcdir}/quail/hanja-jis.elc \
96 ${srcdir}/quail/symbol-ksc.elc
98 THAI=${srcdir}/quail/thai.elc
100 VIETNAMESE=${srcdir}/quail/viqr.elc ${srcdir}/quail/vntelex.elc
102 LAO=${srcdir}/quail/lao.elc ${srcdir}/quail/lrt.elc
104 INDIAN=${srcdir}/quail/indian.elc
106 TIBETAN=${srcdir}/quail/tibetan.elc
108 LATIN= ${srcdir}/quail/latin-pre.elc \
109 ${srcdir}/quail/latin-post.elc \
110 ${srcdir}/quail/latin-alt.elc \
111 ${srcdir}/quail/latin-ltx.elc \
112 ${srcdir}/quail/welsh.elc
114 UNICODE=${srcdir}/quail/sgml-input.elc ${srcdir}/quail/rfc1345.elc \
115 ${srcdir}/quail/uni-input.elc
117 SLAVIC= \
118 ${srcdir}/quail/czech.elc \
119 ${srcdir}/quail/croatian.elc \
120 ${srcdir}/quail/slovak.elc
122 GREEK=${srcdir}/quail/greek.elc
124 RUSSIAN=${srcdir}/quail/cyrillic.elc ${srcdir}/quail/cyril-jis.elc
126 OTHERS= \
127 ${srcdir}/quail/ethiopic.elc \
128 ${srcdir}/quail/ipa.elc \
129 ${srcdir}/quail/hebrew.elc \
130 ${srcdir}/quail/georgian.elc \
131 ${srcdir}/quail/sisheng.elc
133 MISC= \
134 quail/tsang-b5.elc \
135 quail/quick-b5.elc \
136 quail/tsang-cns.elc \
137 quail/quick-cns.elc \
138 quail/PY.elc \
139 quail/ZIRANMA.elc \
140 quail/CTLau.elc \
141 quail/CTLau-b5.elc
143 CHINESE=${CHINESE-GB} ${CHINESE-BIG5}
144 EASTASIA=${CHINESE} ${JAPANESE} ${KOREAN}
145 ASIA=${EASTASIA} ${THAI} ${VIETNAMESE} ${LAO} ${INDIAN} ${TIBETAN}
146 EUROPEAN=${LATIN} ${SLAVIC} ${GREEK} ${RUSSIAN}
147 WORLD=${ASIA} ${EUROPEAN} ${OTHERS} ${MISC} ${UNICODE}
149 TIT-MISC=${CHINESE-TIT} ${MISC}
150 NON-TIT-MISC=${CHINESE-NON-TIT} ${JAPANESE} ${KOREAN} ${EUROPEAN} ${OTHERS}
152 .SUFFIXES: .elc .el
154 .el.elc:
155 ${RUN-EMACS} -f batch-byte-compile $<
157 all: ${BUILT-EMACS} ${SUBDIRS} leim-list.el ${WORLD}
159 # To ensure that we can run Emacs. This target is ignored (never
160 # being hit) if a user changes default value of EMACS.
161 ${dot}${dot}/src/emacs:
162 cd ../src; ${MAKE} ${MFLAGS} emacs
164 ${SUBDIRS}:
165 mkdir $@
166 touch stamp-subdir
168 TIT-SOURCES= \
169 ${srcdir}/CXTERM-DIC/4Corner.tit \
170 ${srcdir}/CXTERM-DIC/ARRAY30.tit \
171 ${srcdir}/CXTERM-DIC/CCDOSPY.tit \
172 ${srcdir}/CXTERM-DIC/ECDICT.tit \
173 ${srcdir}/CXTERM-DIC/ETZY.tit \
174 ${srcdir}/CXTERM-DIC/PY-b5.tit \
175 ${srcdir}/CXTERM-DIC/Punct-b5.tit \
176 ${srcdir}/CXTERM-DIC/Punct.tit \
177 ${srcdir}/CXTERM-DIC/QJ-b5.tit \
178 ${srcdir}/CXTERM-DIC/QJ.tit \
179 ${srcdir}/CXTERM-DIC/SW.tit \
180 ${srcdir}/CXTERM-DIC/TONEPY.tit \
181 ${srcdir}/CXTERM-DIC/ZOZY.tit
183 ${CHINESE-TIT:.elc=.el}: changed.tit
184 @true
186 changed.tit: ${TIT-SOURCES}
187 ${RUN-EMACS} -l ${buildlisppath}/international/titdic-cnv \
188 -f batch-titdic-convert -dir quail ${srcdir}/CXTERM-DIC; \
189 echo "changed" > $@
191 MISC-SOURCES= \
192 ${srcdir}/MISC-DIC/CTLau-b5.html \
193 ${srcdir}/MISC-DIC/CTLau.html \
194 ${srcdir}/MISC-DIC/cangjie-table.b5 \
195 ${srcdir}/MISC-DIC/cangjie-table.cns \
196 ${srcdir}/MISC-DIC/pinyin.map \
197 ${srcdir}/MISC-DIC/ziranma.cin
199 ${MISC:.elc=.el}: changed.misc
200 @true
202 changed.misc: ${MISC-SOURCES}
203 ${RUN-EMACS} -l ${buildlisppath}/international/titdic-cnv \
204 -f batch-miscdic-convert -dir quail ${srcdir}/MISC-DIC; \
205 echo "changed" > $@
207 leim-list.el: ${SUBDIRS} ${TIT-MISC} changed.tit changed.misc ${srcdir}/leim-ext.el
208 ${RUN-EMACS} -l ${buildlisppath}/international/quail \
209 -f batch-byte-compile-if-not-done ${TIT-MISC:.elc=.el}
210 if [ x`(cd ${srcdir} && /bin/pwd)` = x`(/bin/pwd)` ] ; then \
211 ${RUN-EMACS} -l ${buildlisppath}/international/quail \
212 --eval "(update-leim-list-file \".\")" ; \
213 else \
214 ${RUN-EMACS} -l ${buildlisppath}/international/quail \
215 --eval "(update-leim-list-file \".\" \"${srcdir}\")" ; \
217 sed -n '/^[^;]/ p' < ${srcdir}/leim-ext.el >> $@
219 install: all
220 if [ ! -d ${INSTALLDIR} ] ; then \
221 ${srcdir}/${dot}${dot}/mkinstalldirs ${INSTALLDIR}; \
222 else true; fi
223 if [ x`(cd ${INSTALLDIR} && /bin/pwd)` != x`(/bin/pwd)` ] ; then \
224 rm -rf ${INSTALLDIR}/leim-list.el; \
225 rm -rf ${INSTALLDIR}/quail ${INSTALLDIR}/ja-dic ; \
226 echo "Copying leim files to ${INSTALLDIR} ..." ; \
227 if [ x`(cd ${srcdir} && /bin/pwd)` = x`(/bin/pwd)` ] ; then \
228 tar -chf - leim-list.el quail ja-dic \
229 | (cd ${INSTALLDIR}; umask 0; tar -xvf - && cat > /dev/null) ;\
230 else \
231 tar -chf - leim-list.el quail \
232 | (cd ${INSTALLDIR}; umask 0; tar -xvf - && cat > /dev/null) ;\
233 cd ${srcdir}; \
234 tar -chf - quail/* ja-dic \
235 | (cd ${INSTALLDIR}; umask 0; tar -xvf - && cat > /dev/null) ;\
236 fi; \
237 rm -rf ${INSTALLDIR}/CVS ${INSTALLDIR}/*/CVS; \
238 rm -f ${INSTALLDIR}/.cvsignore ${INSTALLDIR}/*/.cvsignore; \
239 rm -f ${INSTALLDIR}/.arch-inventory ${INSTALLDIR}/*/.arch-inventory; \
240 rm -f ${INSTALLDIR}/\#* ${INSTALLDIR}/*/\#* ; \
241 rm -f ${INSTALLDIR}/.\#* ${INSTALLDIR}/*/.\#* ; \
242 rm -f ${INSTALLDIR}/*~ ${INSTALLDIR}/*/*~ ; \
243 rm -f ${INSTALLDIR}/*.orig ${INSTALLDIR}/*/*.orig ; \
244 else true; fi
245 -unset CDPATH; \
246 if [ -n "${GZIP_PROG}" ]; \
247 then \
248 echo "Compressing *.el ..." ; \
249 (cd ${INSTALLDIR}; for f in `find . -name "*.elc" -print`; do \
250 ${GZIP_PROG} -9n `echo $$f|sed 's/.elc$$/.el/'` ; \
251 done) \
252 else true; fi
253 -chmod -R a+r ${INSTALLDIR}
254 for installuser in $${LOGNAME} $${USERNAME} $${USER} \
255 `id -un 2> /dev/null`; do \
256 [ -n "$${installuser}" ] && break ; \
257 done ; \
258 find ${INSTALLDIR} -exec chown $${installuser} '{}' ';'
260 clean mostlyclean:
261 rm -f ${TIT-MISC} ${TIT-MISC:.elc=.el} \
262 leim-list.el changed.tit changed.misc
264 # The following target is needed because the `clean' target only removes
265 # TIT-generated files and doesn't touch compiled Quail packages. But
266 # bootstrapping should not leave non-fresh .elc files behind.
267 bootstrap-clean: clean
268 rm -f ${WORLD}
270 distclean: clean
271 if test -f stamp-subdir; then rm -rf ${SUBDIRS} stamp-subdir; fi
272 rm -f Makefile
274 maintainer-clean: distclean
275 rm -f ${WORLD}
277 extraclean: maintainer-clean
278 -rm -f *~ \#* m/?*~ s/?*~
280 .PHONY: check-declare
282 check-declare:
283 $(RUN-EMACS) -l $(buildlisppath)/emacs-lisp/check-declare \
284 --eval '(check-declare-directory "$(srcdir)")'