diff options
Diffstat (limited to 'samples/Makefile')
-rw-r--r-- | samples/Makefile | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/samples/Makefile b/samples/Makefile new file mode 100644 index 0000000..518ec87 --- /dev/null +++ b/samples/Makefile | |||
@@ -0,0 +1,26 @@ | |||
1 | SHELL = bash | ||
2 | CMP = lualatex-dev | ||
3 | PWD = $(shell pwd) | ||
4 | |||
5 | exts := .tex .pdf -tei.xml | ||
6 | texsamples := $(basename $(wildcard $(PWD)/*.tex)) | ||
7 | findopts := $(foreach ext,$(exts),-or -iname "*$(ext)") | ||
8 | |||
9 | define dosamples | ||
10 | $(CMP) --shell-escape $1 >/dev/null | ||
11 | $(CMP) --shell-escape $1 >/dev/null | ||
12 | $(CMP) --shell-escape $1 >/dev/null | ||
13 | $(CMP) --shell-escape $1 >/dev/null | ||
14 | endef | ||
15 | |||
16 | |||
17 | all: | ||
18 | cp ../ekdosis.{lua,sty} . | ||
19 | $(foreach file,$(texsamples), $(call dosamples, $(file))) | ||
20 | rm -rf auto | ||
21 | find -iname "*~" -or -iname "*_out*.tex" | xargs rm -rf | ||
22 | find ./* -type f -iname "Makefile" $(findopts) > ls-R | ||
23 | rsync -aPr --files-from=ls-R . .backup | ||
24 | rm -rf * | ||
25 | cp -p -r .backup/* . | ||
26 | rm -rf .backup | ||