-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
56 lines (39 loc) · 1.2 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
#(********************************************************************)
#(* Antelatex - Makefile *)
#(********************************************************************)
#(* $Time-stamp: <Pierre-Malo Denielou - 2012>$ *)
BINDIR := /usr/local/bin
VERSION := `cat VERSION`
all: byte native
src/version.ml: VERSION
echo 'let version ="' | cat - VERSION > src/version.ml
echo '"' >> src/version.ml
native: src/version.ml
ocamlbuild src/antelatex.native
byte: src/version.ml
ocamlbuild src/antelatex.byte
clean:
ocamlbuild -clean
rm -f src/version.ml
rm -f *~
rm -f src/*~
rm -f ex/test.tex
install: install-native
install-native:
cp _build/src/antelatex.native $(BINDIR)/antelatex
install-byte:
cp _build/src/antelatex.native $(BINDIR)/antelatex
test: test-native
test-native:
./antelatex.native -g ex/grammar.gra ex/test.ant
test-byte:
./antelatex.byte -g ex/grammar.gra ex/test.ant
dist: clean
mkdir tmp
cp -f AUTHORS CHANGELOG LICENSE Makefile NEWS README TODO VERSION tmp/
cp -r src/ tmp/
cp -r ex/ tmp/
mv tmp antelatex-$(VERSION)
tar -cf antelatex-$(VERSION).tar antelatex-$(VERSION)
gzip antelatex-$(VERSION).tar
rm -rf antelatex-$(VERSION)