]> matita.cs.unibo.it Git - helm.git/blob - helm/software/matita/contribs/LAMBDA-TYPES/Makefile
LAMBDA-TYPES:
[helm.git] / helm / software / matita / contribs / LAMBDA-TYPES / Makefile
1 H=@
2
3 MATITAOPTIONS=-onepass
4
5 DIR=$(shell basename $$PWD)
6
7 MMAS = $(shell find Base-2 -name "*.mma")
8 MAS = $(MMAS:%.mma=%.ma)
9 XMAS = Base-2/theory.ma
10
11 $(DIR) all: depends
12         $(H)$(MAKE) --no-print-directory build
13
14 $(DIR).opt opt all.opt: depends
15         $(H)$(MAKE) --no-print-directory build.opt
16
17 build: $(MAS)
18         $(H)$echo Base-2/theory.ma `../../matitadep.opt -stdout Base-2/theory.ma` >> depends
19         $(H)../../matitac $(MATITAOPTIONS) 2> /dev/null
20         $(H)rm depends
21
22 build.opt: $(MAS)
23         $(H)echo Base-2/theory.ma `../../matitadep.opt -stdout Base-2/theory.ma` >> depends
24         $(H)../../matitac.opt $(MATITAOPTIONS) 2> /dev/null
25         $(H)rm depends
26
27 clean:
28         $(H)../../matitaclean
29         $(H)rm -f $(MAS) depends
30
31 clean.opt:
32         $(H)../../matitaclean.opt
33         $(H)rm -f $(MAS) depends
34
35 clean.ma:
36         $(H)../../matitaclean.opt $(MAS)
37         $(H)rm -f $(MAS) depends
38
39 depend:
40         @echo matitadep
41         $(H)../../matitadep $(foreach FILE,$(XMAS),-exclude $(FILE))
42         $(H)cat Base-2/depends >> depends
43 depend.opt:
44         @echo matitadep.opt
45         $(H)../../matitadep.opt $(foreach FILE,$(XMAS),-exclude $(FILE))
46         $(H)cat Base-2/depends >> depends
47
48 depends: depend.opt
49
50 %.ma: %.mma
51         $(H)../../matitac.opt $(MATITAOPTIONS) `../../matitadep.opt -stdout $<` 2> /dev/null
52         $(H)../../matitac.opt $(MATITAOPTIONS) -dump $@ $< 2> /dev/null
53         $(H)echo $@ `../../matitadep.opt -stdout $@` >> depends
54
55 include Base-2/.depend