]> Git — Sourcephile - comptalang.git/blob - Makefile
Correction : Calc.Balance : union => unionWith : évite une éventuelle surprise.
[comptalang.git] / Makefile
1 all: install
2 .PHONY: .
3
4 #
5 ## install
6 ###
7 install: cabal/install lib/install cli/install web/install
8 cabal/install:
9 cabal update $(CABAL_FLAGS) $(CABAL_UPDATE_FLAGS)
10 cabal install -v $(CABAL_FLAGS) $(CABAL_INSTALL_FLAGS) cabal
11 .PHONY: lib cli web
12 lib lib/install:
13 cabal install -v --force-reinstalls $(CABAL_FLAGS) $(CABAL_INSTALL_FLAGS) ./lib
14 cli cli/install:
15 cabal install -v --force-reinstalls $(CABAL_FLAGS) $(CABAL_INSTALL_FLAGS) ./cli
16 web web/install:
17 cabal install -v --force-reinstalls $(CABAL_FLAGS) $(CABAL_INSTALL_FLAGS) ./web
18
19 #
20 ## test
21 ###
22 test: lib/test cli/test web/test
23 lib/test:
24 (cd lib && cabal test --show-details=always $(CABAL_FLAGS) $(CABAL_TEST_FLAGS))
25 cli/test:
26 (cd cli && cabal test --show-details=always $(CABAL_FLAGS) $(CABAL_TEST_FLAGS))
27 web/test:
28 (cd web && cabal test --show-details=always $(CABAL_FLAGS) $(CABAL_TEST_FLAGS))
29 %/install/test: CABAL_INSTALL_FLAGS+=--enable-tests
30 %/install/test: %/install
31
32
33 #
34 ## doc
35 ###
36 .PHONY: doc
37 doc: doc/xhtml lib/doc cli/doc web/doc
38 lib/doc:
39 (cd lib && cabal haddock --hyperlink-source $(CABAL_FLAGS) $(CABAL_HADDOCK_FLAGS))
40 cli/doc:
41 (cd cli && cabal haddock --hyperlink-source $(CABAL_FLAGS) $(CABAL_HADDOCK_FLAGS))
42 web/doc:
43 (cd web && cabal haddock --hyperlink-source $(CABAL_FLAGS) $(CABAL_HADDOCK_FLAGS))
44 doc/%: .
45 $(MAKE) -C doc $*
46
47 #
48 ## dev
49 ###
50 %/dev: CABAL_INSTALL_FLAGS+=-fdev
51 %/dev: %
52
53 #