summaryrefslogtreecommitdiffstats
path: root/runtime/syntax/generator/Makefile
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-13 07:39:57 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-13 07:40:16 +0000
commit6af24b2457752c0d36aaf9f29f03d39afd09937f (patch)
tree2671b594908d1f971de6b2a2d473f97dfb7291d2 /runtime/syntax/generator/Makefile
parentReleasing progress-linux version 2:9.1.0016-1~progress7.99u1. (diff)
downloadvim-6af24b2457752c0d36aaf9f29f03d39afd09937f.tar.xz
vim-6af24b2457752c0d36aaf9f29f03d39afd09937f.zip
Merging upstream version 2:9.1.0199.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'runtime/syntax/generator/Makefile')
-rw-r--r--runtime/syntax/generator/Makefile43
1 files changed, 43 insertions, 0 deletions
diff --git a/runtime/syntax/generator/Makefile b/runtime/syntax/generator/Makefile
new file mode 100644
index 0000000..3cf4b95
--- /dev/null
+++ b/runtime/syntax/generator/Makefile
@@ -0,0 +1,43 @@
+VIM_SRCDIR = ../../../src
+RUN_VIM = $(VIM_SRCDIR)/vim -N -u NONE -i NONE -n
+REVISION ?= $(shell date +%Y-%m-%dT%H:%M:%S%:z)
+
+SRC = $(VIM_SRCDIR)/eval.c $(VIM_SRCDIR)/ex_cmds.h $(VIM_SRCDIR)/ex_docmd.c \
+ $(VIM_SRCDIR)/fileio.c $(VIM_SRCDIR)/option.c $(VIM_SRCDIR)/syntax.c
+
+export VIM_SRCDIR
+
+.PHONY: generate clean
+all: generate
+
+generate: vim.vim
+
+vim.vim: vim.vim.rc update_date.vim
+ @echo "Generating vim.vim ..."
+ @cp -f vim.vim.rc ../vim.vim
+ @$(RUN_VIM) -S update_date.vim
+ @echo "done."
+
+vim.vim.rc: gen_syntax_vim.vim vim.vim.base $(SRC)
+ @echo "Generating vim.vim.rc ..."
+ @rm -f sanity_check.err generator.err
+ @$(RUN_VIM) -S gen_syntax_vim.vim
+ @if test -f sanity_check.err ; then \
+ echo ; \
+ echo "Sanity errors:" ; \
+ cat sanity_check.err ; \
+ exit 1 ; \
+ fi
+ @if test -f generator.err ; then \
+ echo ; \
+ echo "Generator errors:" ; \
+ cat generator.err ; \
+ echo ; \
+ exit 1 ; \
+ fi
+ @echo "done."
+
+clean:
+ rm -f vim.vim.rc
+ rm -f vim.vim
+ rm -f sanity_check.err generator.err