]> gitweb.michael.orlitzky.com - numerical-analysis.git/blob - makefile
Speed up the Cholesky factorization with a fold.
[numerical-analysis.git] / makefile
1 # There's only one '$' in the awk script, but we have to double-money
2 # it for make.
3 PN = $(shell grep 'name:' *.cabal | awk '{ print $$2 }')
4 BIN = dist/build/$(PN)/$(PN)
5 DOCTESTS_BIN = dist/build/doctests/doctests
6 SRCS = $(shell find src/ -name '*.hs')
7
8 .PHONY : test publish_doc doc dist hlint
9
10 $(BIN): $(PN).cabal $(SRCS)
11 runghc Setup.hs configure --user
12 runghc Setup.hs build
13
14 $(DOCTESTS_BIN): $(SRCS) test/Doctests.hs
15 runghc Setup.hs configure --user --enable-tests
16 runghc Setup.hs build
17
18
19 profile: $(PN).cabal $(SRCS)
20 runghc Setup.hs configure --user --enable-executable-profiling
21 runghc Setup.hs build
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
34 doc: $(SRCS)
35 runghc Setup.hs configure --user --flags=${FLAGS}
36 runghc Setup.hs hscolour --all
37 runghc Setup.hs haddock --all \
38 --haddock-options="--ignore-all-exports"
39
40 hlint:
41 hlint --ignore="Use camelCase" \
42 --ignore="Redundant bracket" \
43 --color \
44 src