-
Notifications
You must be signed in to change notification settings - Fork 3
/
Makefile
86 lines (60 loc) · 2.08 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
.PHONY: test compile clean
#VERSION := $(shell git describe --tags)
VERSION := "0.4.2"
ELPKG := standoff-api.el \
standoff-dummy.el \
standoff-log.el \
standoff-util.el \
standoff-mark.el \
standoff-json.el \
standoff-json-file.el \
standoff-xml.el \
standoff-relations.el \
standoff-mode.el \
standoff-mode-pkg.el \
standoff-en.info \
standoff-de.info \
dir
DOC_HTML := docs/en/index.html docs/arb/index.html docs/de/index.html
DOC_INFO := standoff-en.info standoff-de.info
DOC_PDF := standoff-en.pdf standoff-arb.pdf standoff-de.pdf
# Note: The manual for the ``Praktikum'' must be generated before the
# regular manual, because the praktikum manual overwrites the files
# for regular manual as temporary files
RM_DIRS :=
DOC_TMP := standoff-{en,de}\.{aux,cp,dvi,fn,ky,log,pg,tmp,toc,tp,vr,fns,vrs,kys}
ELC := $(patsubst %.el,%.elc,$(wildcard *.el))
%.elc: %.el
emacs -Q -batch -L `pwd` -f batch-byte-compile $<
html : ${DOC_HTML}
info : ${DOC_INFO}
pdf : ${DOC_PDF}
standoff-en.info : standoff-en.texi version.texi
makeinfo standoff-en.texi
standoff-en.pdf : standoff-en.texi version.texi
texi2pdf standoff-en.texi
docs/en/index.html : standoff-en.texi version.texi
makeinfo --html --output=docs/en/ standoff-en.texi
standoff-de.info : standoff-de.texi version.texi
makeinfo standoff-de.texi
standoff-de.pdf : standoff-de.texi version.texi
texi2pdf standoff-de.texi
docs/de/index.html : standoff-de.texi version.texi
makeinfo --html --output=docs/de/ standoff-de.texi
standoff-praktikum.pdf : standoff-de.texi version.texi
texi2pdf -o standoff-praktikum.pdf -t "@set PRAKTIKUM" standoff-de.texi
docs/arb/index.html : standoff-de.texi version.texi
makeinfo --html -D PRAKTIKUM --output=docs/arb standoff-de.texi
package : standoff-mode-$(VERSION).tar
standoff-mode-$(VERSION).tar: ${ELPKG} README.md LICENSE
tar -cf $@ --transform "s,^,standoff-mode-$(VERSION)/," $^
test:
@for idx in test/*-test.el; do \
printf '* %s\n' $$idx ; \
./$$idx ; \
[ $$? -ne 0 ] && exit 1 ; \
done; :
compile: $(ELC)
clean:
rm *.tar *.elc ${DOC_TMP} ${DOC_INFO} ${DOC_PDF}; \
rm -Rf ${RM_DIRS}