Revision 15f4c8ca Makefile

b/Makefile
1
HPROGS = hbal hn1 hscan hail
1
HPROGS = hbal hn1 hscan hail test
2 2
HSRCS := $(wildcard Ganeti/HTools/*.hs)
3 3
HDDIR = apidoc
4 4

  
5 5
DOCS = README.html NEWS.html
6 6

  
7
HFLAGS = -O2 -W -fwarn-monomorphism-restriction -fwarn-tabs
8
HEXTRA =
9

  
10
HPCEXCL = --exclude Main --exclude Ganeti.HTools.QC
11

  
7 12
# Haskell rules
8 13

  
9 14
all: $(HPROGS)
10 15

  
11 16
$(HPROGS): %: %.hs Ganeti/HTools/Version.hs $(HSRCS) Makefile
12
	ghc --make -O2 -W $@
17
	ghc --make $(HFLAGS) $(HEXTRA) $@
13 18

  
14 19
$(DOCS) : %.html : %
15 20
	rst2html $< $@
......
53 58
	gzip -v9 $$ANAME ; \
54 59
	tar tzvf $$ANAME.gz
55 60

  
56
.PHONY : all doc maintainer-clean clean dist
61
check:
62
	rm -f *.tix *.mix test
63
	$(MAKE) HEXTRA=-fhpc test
64
	./test
65
ifeq ($(T),markup)
66
	mkdir -p coverage
67
	hpc markup --destdir=coverage test $(HPCEXCL)
68
else
69
	hpc report test $(HPCEXCL)
70
endif
71

  
72
.PHONY : all doc maintainer-clean clean dist check

Also available in: Unified diff