diff options
| author | Eli Zaretskii | 2011-08-15 20:47:25 +0300 |
|---|---|---|
| committer | Eli Zaretskii | 2011-08-15 20:47:25 +0300 |
| commit | 474a84653b4aa5a10b49af751c3008a4c582422c (patch) | |
| tree | 352c73a638573275b43ddd941bad2c6e6c7e9d9b /admin | |
| parent | 934eacb93d0b8340a3a8b478deaa6110a3de083f (diff) | |
| download | emacs-474a84653b4aa5a10b49af751c3008a4c582422c.tar.gz emacs-474a84653b4aa5a10b49af751c3008a4c582422c.zip | |
Use uniprop tables instead of biditype.h and bidimirror.h.
src/bidi.c (bidi_initialize): Use uniprop_table instead of including
biditype.h and bidimirror.h.
src/biditype.h: File removed.
src/bidimirror.h: File removed.
src/deps.mk (bidi.o): Remove biditype.h and
bidimirror.h.
src/makefile.w32-in ($(BLD)/bidi.$(O)): Remove biditype.h and
bidimirror.h.
src/dispextern.h: Fix a typo in the comment to bidi_type_t.
src/chartab.c: Improve commentary for the uniprop_table API.
admin/unidata/bidimirror.awk: File removed.
admin/unidata/biditype.awk: File removed.
admin/unidata/makefile.w32-in (all): Remove src/biditype.h and
src/bidimirror.h.
(../../src/biditype.h, ../../src/bidimirror.h): Deleted.
admin/unidata/Makefile.in (all): Remove src/biditype.h and
src/bidimirror.h.
(../../src/biditype.h, ../../src/bidimirror.h): Deleted.
Diffstat (limited to 'admin')
| -rw-r--r-- | admin/ChangeLog | 14 | ||||
| -rw-r--r-- | admin/unidata/Makefile.in | 8 | ||||
| -rw-r--r-- | admin/unidata/bidimirror.awk | 37 | ||||
| -rw-r--r-- | admin/unidata/biditype.awk | 93 | ||||
| -rw-r--r-- | admin/unidata/makefile.w32-in | 12 |
5 files changed, 16 insertions, 148 deletions
diff --git a/admin/ChangeLog b/admin/ChangeLog index dbbe38ce617..bc38edfc8d4 100644 --- a/admin/ChangeLog +++ b/admin/ChangeLog | |||
| @@ -1,3 +1,17 @@ | |||
| 1 | 2011-08-15 Eli Zaretskii <eliz@gnu.org> | ||
| 2 | |||
| 3 | * unidata/bidimirror.awk: File removed. | ||
| 4 | |||
| 5 | * unidata/biditype.awk: File removed. | ||
| 6 | |||
| 7 | * unidata/makefile.w32-in (all): Remove src/biditype.h and | ||
| 8 | src/bidimirror.h. | ||
| 9 | (../../src/biditype.h, ../../src/bidimirror.h): Deleted. | ||
| 10 | |||
| 11 | * unidata/Makefile.in (all): Remove src/biditype.h and | ||
| 12 | src/bidimirror.h. | ||
| 13 | (../../src/biditype.h, ../../src/bidimirror.h): Deleted. | ||
| 14 | |||
| 1 | 2011-07-07 Juanma Barranquero <lekktu@gmail.com> | 15 | 2011-07-07 Juanma Barranquero <lekktu@gmail.com> |
| 2 | 16 | ||
| 3 | * unidata/makefile.w32-in (charprop-SH, charprop-CMD): | 17 | * unidata/makefile.w32-in (charprop-SH, charprop-CMD): |
diff --git a/admin/unidata/Makefile.in b/admin/unidata/Makefile.in index e1fe247631f..c890dad8903 100644 --- a/admin/unidata/Makefile.in +++ b/admin/unidata/Makefile.in | |||
| @@ -23,7 +23,7 @@ EMACS = ../../src/emacs | |||
| 23 | DSTDIR = ../../lisp/international | 23 | DSTDIR = ../../lisp/international |
| 24 | RUNEMACS = ${EMACS} -Q -batch | 24 | RUNEMACS = ${EMACS} -Q -batch |
| 25 | 25 | ||
| 26 | all: ${DSTDIR}/charprop.el ../../src/biditype.h ../../src/bidimirror.h | 26 | all: ${DSTDIR}/charprop.el |
| 27 | 27 | ||
| 28 | .el.elc: | 28 | .el.elc: |
| 29 | ${RUNEMACS} -batch -f batch-byte-compile $< | 29 | ${RUNEMACS} -batch -f batch-byte-compile $< |
| @@ -38,12 +38,6 @@ ${DSTDIR}/charprop.el: unidata-gen.elc unidata.txt | |||
| 38 | cd ${DSTDIR}; \ | 38 | cd ${DSTDIR}; \ |
| 39 | ${RUNEMACS} -batch --load $${ELC} -f unidata-gen-files $${DATADIR} $${DATA} | 39 | ${RUNEMACS} -batch --load $${ELC} -f unidata-gen-files $${DATADIR} $${DATA} |
| 40 | 40 | ||
| 41 | ../../src/biditype.h: UnicodeData.txt | ||
| 42 | gawk -F";" -f biditype.awk $< > $@ | ||
| 43 | |||
| 44 | ../../src/bidimirror.h: BidiMirroring.txt | ||
| 45 | gawk -F"[; ]+" -f bidimirror.awk $< > $@ | ||
| 46 | |||
| 47 | install: charprop.el | 41 | install: charprop.el |
| 48 | cp charprop.el ${DSTDIR} | 42 | cp charprop.el ${DSTDIR} |
| 49 | cp `sed -n 's/^;; FILE: //p' < charprop.el` ${DSTDIR} | 43 | cp `sed -n 's/^;; FILE: //p' < charprop.el` ${DSTDIR} |
diff --git a/admin/unidata/bidimirror.awk b/admin/unidata/bidimirror.awk deleted file mode 100644 index fc3e8afaace..00000000000 --- a/admin/unidata/bidimirror.awk +++ /dev/null | |||
| @@ -1,37 +0,0 @@ | |||
| 1 | # Generate data for bidi_mirroring_table, see src/bidi.c:bidi_initialize. | ||
| 2 | |||
| 3 | # Copyright (C) 2010-2011 Free Software Foundation, Inc. | ||
| 4 | |||
| 5 | # This file is part of GNU Emacs. | ||
| 6 | |||
| 7 | # GNU Emacs is free software: you can redistribute it and/or modify | ||
| 8 | # it under the terms of the GNU General Public License as published by | ||
| 9 | # the Free Software Foundation, either version 3 of the License, or | ||
| 10 | # (at your option) any later version. | ||
| 11 | |||
| 12 | # GNU Emacs is distributed in the hope that it will be useful, | ||
| 13 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 14 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 15 | # GNU General Public License for more details. | ||
| 16 | |||
| 17 | # You should have received a copy of the GNU General Public License | ||
| 18 | # along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. | ||
| 19 | |||
| 20 | # Written by Eli Zaretskii <eliz@gnu.org> | ||
| 21 | |||
| 22 | BEGIN { | ||
| 23 | printf " struct {\n int from, to;\n } bidi_mirror[] = {\n"; | ||
| 24 | first = 1; | ||
| 25 | } | ||
| 26 | |||
| 27 | $1 !~ /^#/ && NF >= 2 { | ||
| 28 | if (!first) | ||
| 29 | printf ",\n"; | ||
| 30 | else | ||
| 31 | first = 0; | ||
| 32 | printf "\t{ 0x%s, 0x%s }", $1, $2; | ||
| 33 | } | ||
| 34 | |||
| 35 | END { | ||
| 36 | printf " };\n"; | ||
| 37 | } | ||
diff --git a/admin/unidata/biditype.awk b/admin/unidata/biditype.awk deleted file mode 100644 index bb1aaad1973..00000000000 --- a/admin/unidata/biditype.awk +++ /dev/null | |||
| @@ -1,93 +0,0 @@ | |||
| 1 | # Generate data for filling bidi_type_table, see src/bidi.c:bidi_initialize. | ||
| 2 | |||
| 3 | # Copyright (C) 2010-2011 Free Software Foundation, Inc. | ||
| 4 | |||
| 5 | # This file is part of GNU Emacs. | ||
| 6 | |||
| 7 | # GNU Emacs is free software: you can redistribute it and/or modify | ||
| 8 | # it under the terms of the GNU General Public License as published by | ||
| 9 | # the Free Software Foundation, either version 3 of the License, or | ||
| 10 | # (at your option) any later version. | ||
| 11 | |||
| 12 | # GNU Emacs is distributed in the hope that it will be useful, | ||
| 13 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 14 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 15 | # GNU General Public License for more details. | ||
| 16 | |||
| 17 | # You should have received a copy of the GNU General Public License | ||
| 18 | # along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. | ||
| 19 | |||
| 20 | # Written by Eli Zaretskii <eliz@gnu.org> | ||
| 21 | |||
| 22 | function trtype(type) | ||
| 23 | { | ||
| 24 | # Types are listed in the order of decresing use in UnicodeData.txt: | ||
| 25 | if (type == "ON") | ||
| 26 | return "NEUTRAL_ON"; | ||
| 27 | else if (type == "NSM") | ||
| 28 | return "WEAK_NSM"; | ||
| 29 | else if (type == "AL") | ||
| 30 | return "STRONG_AL"; | ||
| 31 | else if (type == "R") | ||
| 32 | return "STRONG_R"; | ||
| 33 | else if (type == "BN") | ||
| 34 | return "WEAK_BN"; | ||
| 35 | else if (type == "EN") | ||
| 36 | return "WEAK_EN"; | ||
| 37 | else if (type == "ET") | ||
| 38 | return "WEAK_ET"; | ||
| 39 | else if (type == "AN") | ||
| 40 | return "WEAK_AN"; | ||
| 41 | else if (type == "WS") | ||
| 42 | return "NEUTRAL_WS"; | ||
| 43 | else if (type == "CS") | ||
| 44 | return "WEAK_CS"; | ||
| 45 | else if (type == "ES") | ||
| 46 | return "WEAK_ES"; | ||
| 47 | else if (type == "B") | ||
| 48 | return "NEUTRAL_B"; | ||
| 49 | else if (type == "S") | ||
| 50 | return "NEUTRAL_S"; | ||
| 51 | else if (type == "LRE" || type == "RLE" || type == "LRO" || type == "RLO" || type == "PDF") | ||
| 52 | return type; | ||
| 53 | else if (type == "L") | ||
| 54 | return "STRONG_L"; | ||
| 55 | else | ||
| 56 | { | ||
| 57 | printf "Unknown type: %s\n", type > "/dev/stderr"; | ||
| 58 | exit 1; | ||
| 59 | } | ||
| 60 | } | ||
| 61 | |||
| 62 | BEGIN { | ||
| 63 | otype = ""; | ||
| 64 | startcode = ""; | ||
| 65 | endcode = ""; | ||
| 66 | printf " struct {\n int from, to;\n bidi_type_t type;\n } bidi_type[] = {\n"; | ||
| 67 | first = 1; | ||
| 68 | } | ||
| 69 | |||
| 70 | { code = $1; | ||
| 71 | ntype = $5; | ||
| 72 | if (ntype != otype) | ||
| 73 | { | ||
| 74 | # Don't output data for L, as that's the default value, see bidi.c. | ||
| 75 | if (otype != "L" && startcode != "") | ||
| 76 | { | ||
| 77 | if (!first) | ||
| 78 | printf ",\n"; | ||
| 79 | else | ||
| 80 | first = 0; | ||
| 81 | printf "\t{ 0x%s, 0x%s, %s }", startcode, endcode, trtype(otype); | ||
| 82 | } | ||
| 83 | otype = ntype; | ||
| 84 | startcode = code; | ||
| 85 | endcode = code; | ||
| 86 | } | ||
| 87 | else | ||
| 88 | endcode = code; | ||
| 89 | } | ||
| 90 | |||
| 91 | END { | ||
| 92 | printf " };\n"; | ||
| 93 | } | ||
diff --git a/admin/unidata/makefile.w32-in b/admin/unidata/makefile.w32-in index 6a877e0c1d0..96a1f5b86fd 100644 --- a/admin/unidata/makefile.w32-in +++ b/admin/unidata/makefile.w32-in | |||
| @@ -29,7 +29,7 @@ EMACSLOADPATH = $(lisp);$(lisp)/international;$(lisp)/emacs-lisp | |||
| 29 | # Quote EMACS so it could be a file name with embedded whitespace | 29 | # Quote EMACS so it could be a file name with embedded whitespace |
| 30 | RUNEMACS = "$(EMACS)" -Q -batch | 30 | RUNEMACS = "$(EMACS)" -Q -batch |
| 31 | 31 | ||
| 32 | all: $(DSTDIR)/charprop.el ../../src/biditype.h ../../src/bidimirror.h | 32 | all: $(DSTDIR)/charprop.el |
| 33 | 33 | ||
| 34 | .el.elc: | 34 | .el.elc: |
| 35 | $(RUNEMACS) -f batch-byte-compile $< | 35 | $(RUNEMACS) -f batch-byte-compile $< |
| @@ -51,16 +51,6 @@ charprop-CMD: unidata-gen.elc unidata.txt | |||
| 51 | 51 | ||
| 52 | ${DSTDIR}/charprop.el: charprop-$(SHELLTYPE) | 52 | ${DSTDIR}/charprop.el: charprop-$(SHELLTYPE) |
| 53 | 53 | ||
| 54 | ../../src/biditype.h: UnicodeData.txt | ||
| 55 | gawk -F";" -f biditype.awk -v BINMODE=2 $< > biditype.h | ||
| 56 | $(CP) biditype.h $@ | ||
| 57 | $(DEL) biditype.h | ||
| 58 | |||
| 59 | ../../src/bidimirror.h: BidiMirroring.txt | ||
| 60 | gawk -F"[; ]+" -f bidimirror.awk -v BINMODE=2 $< > bidimirror.h | ||
| 61 | $(CP) bidimirror.h $@ | ||
| 62 | $(DEL) bidimirror.h | ||
| 63 | |||
| 64 | clean: | 54 | clean: |
| 65 | - $(DEL) unidata-gen.elc unidata.txt biditype.h bidimirror.h | 55 | - $(DEL) unidata-gen.elc unidata.txt biditype.h bidimirror.h |
| 66 | 56 | ||