Add a doctest suite.
[haeredes.git] / makefile
1 BIN = dist/build/haeredes/haeredes
2 TESTSUITE_BIN = dist/build/testsuite/testsuite
3 DOCTESTS_BIN = dist/build/doctests/doctests
4
5 .PHONY : dist doc test
6
7 $(BIN): src/*.hs
8 runghc Setup.hs clean
9 runghc Setup.hs configure --user
10 runghc Setup.hs build
11
12 $(TESTSUITE_BIN): src/*.hs test/TestSuite.hs
13 runghc Setup.hs configure --user --enable-tests
14 runghc Setup.hs build
15
16 $(DOCTESTS_BIN): src/*.hs test/Doctests.hs
17 runghc Setup.hs configure --user --enable-tests
18 runghc Setup.hs build
19
20 clean:
21 runghc Setup.hs clean
22
23 test: $(BIN) $(TESTSUITE_BIN) $(DOCTESTS_BIN)
24 runghc Setup.hs test
25
26 doc:
27 runghc Setup.hs hscolour --executables
28 runghc Setup.hs haddock --internal \
29 --executables \
30 --hyperlink-source
31
32 hlint:
33 hlint --ignore="Use camelCase" \
34 --ignore="Redundant bracket" \
35 --color \
36 src
37
38 dist:
39 runghc Setup.hs configure
40 runghc Setup.hs sdist