# Makefile for leim subdirectory in GNU Emacs.
# Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
-# 2006, 2007, 2008
+# 2006, 2007, 2008, 2009, 2010
# Free Software Foundation, Inc.
# Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
-# 2006, 2007, 2008
+# 2006, 2007, 2008, 2009, 2010
# National Institute of Advanced Industrial Science and Technology (AIST)
# Registration Number H14PRO021
GZIP_PROG = @GZIP_PROG@
-# On IBM RS6000, double-dot gets screwed up.
-dot = .
-
# Which Emacs to use to convert TIT files to Emacs Lisp files,
# byte-compile Emacs Lisp files, and generate the file leim-list.el.
-BUILT-EMACS = ${dot}${dot}/src/emacs
+BUILT-EMACS = ../src/emacs
-buildlisppath=${srcdir}/${dot}${dot}/lisp
+buildlisppath=${srcdir}/../lisp
# How to run Emacs.
RUN-EMACS = EMACSLOADPATH=$(buildlisppath) LC_ALL=C \
# To ensure that we can run Emacs. This target is ignored (never
# being hit) if a user changes default value of EMACS.
-${dot}${dot}/src/emacs:
+../src/emacs:
cd ../src; ${MAKE} ${MFLAGS} emacs
${SUBDIRS}:
echo "changed" > $@
leim-list.el: ${SUBDIRS} ${TIT-MISC} changed.tit changed.misc ${srcdir}/leim-ext.el
- rm -rf leim-list.el
+ rm -f leim-list.el
${RUN-EMACS} -l ${buildlisppath}/international/quail \
-f batch-byte-compile-if-not-done ${TIT-MISC:.elc=.el}
if [ x`(cd ${srcdir} && /bin/pwd)` = x`(/bin/pwd)` ] ; then \
fi
sed -n '/^[^;]/ p' < ${srcdir}/leim-ext.el >> $@
+MV_DIRS = for i in $$dir; do rm -fr `basename "$$i"` ; mv "$$i" . ; done
+
install: all
if [ ! -d ${INSTALLDIR} ] ; then \
- ${srcdir}/${dot}${dot}/mkinstalldirs ${INSTALLDIR}; \
+ umask 022; ${srcdir}/../mkinstalldirs ${INSTALLDIR}; \
else true; fi
if [ x`(cd ${INSTALLDIR} && /bin/pwd)` != x`(/bin/pwd)` ] ; then \
- rm -rf ${INSTALLDIR}/leim-list.el; \
+ rm -f ${INSTALLDIR}/leim-list.el; \
rm -rf ${INSTALLDIR}/quail ${INSTALLDIR}/ja-dic ; \
echo "Copying leim files to ${INSTALLDIR} ..." ; \
if [ x`(cd ${srcdir} && /bin/pwd)` = x`(/bin/pwd)` ] ; then \
tar -chf - quail/* ja-dic \
| (cd ${INSTALLDIR}; umask 0; tar -xvf - && cat > /dev/null) ;\
fi; \
- rm -rf ${INSTALLDIR}/CVS ${INSTALLDIR}/*/CVS; \
- rm -f ${INSTALLDIR}/.cvsignore ${INSTALLDIR}/*/.cvsignore; \
+ rm -f ${INSTALLDIR}/.gitignore ${INSTALLDIR}/*/.gitignore; \
rm -f ${INSTALLDIR}/.arch-inventory ${INSTALLDIR}/*/.arch-inventory; \
rm -f ${INSTALLDIR}/\#* ${INSTALLDIR}/*/\#* ; \
rm -f ${INSTALLDIR}/.\#* ${INSTALLDIR}/*/.\#* ; \
find ${INSTALLDIR} -exec chown $${installuser} '{}' ';'
if [ "${ns_appresdir}" != "" ]; then \
( cd ${ns_appresdir} ; \
- if test -d share/emacs ; then mv -f share/emacs/*/* . ; fi ; \
+ if test -d share/emacs ; then dir=share/emacs/*/*; $(MV_DIRS); fi;\
rm -fr share ) ; \
else true ; fi
# bootstrapping should not leave non-fresh .elc files behind.
bootstrap-clean: clean
rm -f ${WORLD}
+## FIXME some compiled files go to srcdir, some don't?
+# cd ${srcdir}; rm -f *.elc */*.elc
distclean: clean
if test -f stamp-subdir; then rm -rf ${SUBDIRS} stamp-subdir; fi
rm -f Makefile
-maintainer-clean: distclean
- rm -f ${WORLD}
+maintainer-clean: distclean bootstrap-clean
extraclean: maintainer-clean
- -rm -f *~ \#* m/?*~ s/?*~
+ -rm -f *~ \#* */*~ */\#*
.PHONY: check-declare