]> gitweb.michael.orlitzky.com - numerical-analysis.git/blob - makefile
Add the numerical-analysis Haskell library.
[numerical-analysis.git] / makefile
1 BIN = dist/build/numerical-analysis/numerical-analysis
2 DOCTESTS_BIN = dist/build/doctests/doctests
3
4 .PHONY : test publish_doc doc dist hlint
5
6 $(BIN): src/*.hs
7 runghc Setup.hs clean
8 runghc Setup.hs configure --user --flags=${FLAGS}
9 runghc Setup.hs build
10
11 $(DOCTESTS_BIN): src/*.hs test/Doctests.hs
12 runghc Setup.hs configure --user --flags=${FLAGS} --enable-tests
13 runghc Setup.hs build
14
15
16 profile: src/*.hs
17 runghc Setup.hs configure --user --enable-executable-profiling
18 runghc Setup.hs build
19
20 hpc: src/*.hs
21 FLAGS="hpc" make
22
23 clean:
24 runghc Setup.hs clean
25 rm -f dist/
26 rm -f *.prof
27 rm -rf .hpc
28
29
30 test: $(BIN) $(DOCTESTS_BIN)
31 runghc Setup.hs test
32
33 dist:
34 runghc Setup.hs configure
35 runghc Setup.hs sdist
36
37 # Neither 'haddock' nor 'hscolour' seem to work properly.
38 doc: src/*.hs
39 runghc Setup.hs configure --user --flags=${FLAGS}
40 runghc Setup.hs hscolour --executables
41 runghc Setup.hs haddock --internal \
42 --executables \
43 --hyperlink-source
44
45 hlint:
46 hlint --ignore="Use camelCase" \
47 --ignore="Redundant bracket" \
48 --color \
49 src