Makefile.in 1.78 KB
Newer Older
Kenichi Handa's avatar
Kenichi Handa committed
1
# Makefile -- Makefile to generate character property tables.
2
# Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011
Kenichi Handa's avatar
Kenichi Handa committed
3 4 5 6 7
#   National Institute of Advanced Industrial Science and Technology (AIST)
#   Registration Number H13PRO009
#
# This file is part of GNU Emacs.

8
# GNU Emacs is free software: you can redistribute it and/or modify
Kenichi Handa's avatar
Kenichi Handa committed
9
# it under the terms of the GNU General Public License as published by
10 11
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
Kenichi Handa's avatar
Kenichi Handa committed
12 13 14 15 16 17 18

# GNU Emacs is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.

# You should have received a copy of the GNU General Public License
19 20
# along with GNU Emacs.  If not, see <http://www.gnu.org/licenses/>.

Kenichi Handa's avatar
Kenichi Handa committed
21

22
EMACS = ../../src/emacs
Kenichi Handa's avatar
Kenichi Handa committed
23
DSTDIR = ../../lisp/international
24
RUNEMACS = ${EMACS} -Q -batch
Kenichi Handa's avatar
Kenichi Handa committed
25

26
all: ${DSTDIR}/charprop.el ../../src/biditype.h ../../src/bidimirror.h
Kenichi Handa's avatar
Kenichi Handa committed
27

28 29
.el.elc:
	${RUNEMACS} -batch -f batch-byte-compile $<
Kenichi Handa's avatar
Kenichi Handa committed
30

Kenichi Handa's avatar
Kenichi Handa committed
31
unidata.txt: UnicodeData.txt
32
	sed -e 's/\([^;]*\);\(.*\)/(#x\1 "\2")/' -e 's/;/" "/g' < UnicodeData.txt > $@
Kenichi Handa's avatar
Kenichi Handa committed
33

34 35 36 37 38
${DSTDIR}/charprop.el: unidata-gen.elc unidata.txt
	ELC=`/bin/pwd`/unidata-gen.elc; \
	DATA=`/bin/pwd`/unidata.txt; \
	cd ${DSTDIR}; \
	${RUNEMACS} -batch --load $${ELC} -f unidata-gen-files $${DATA}
Kenichi Handa's avatar
Kenichi Handa committed
39

40 41 42
../../src/biditype.h: UnicodeData.txt
	gawk -F";" -f biditype.awk $< > $@

43 44 45
../../src/bidimirror.h: BidiMirroring.txt
	gawk -F"[; ]+" -f bidimirror.awk $< > $@

Kenichi Handa's avatar
Kenichi Handa committed
46 47 48 49 50 51 52 53
install: charprop.el
	cp charprop.el ${DSTDIR}
	cp `sed -n 's/^;; FILE: //p' < charprop.el` ${DSTDIR}

clean:
	if test -f charprop.el; then \
	  rm -f `sed -n 's/^;; FILE: //p' < charprop.el`; \
	fi
Kenichi Handa's avatar
Kenichi Handa committed
54
	rm -f charprop.el unidata-gen.elc unidata.txt