]> gitweb.michael.orlitzky.com - spline3.git/blob - makefile
Update the makefile to use Cabal.
[spline3.git] / makefile
1 .PHONY : test publish_doc doc src_html hlint
2
3 spline3: src/*.hs
4 runghc Setup.hs clean
5 runghc Setup.hs configure --user --flags=${FLAGS}
6 runghc Setup.hs build
7
8 llvm: src/*.hs
9 FLAGS="llvm" make
10
11 profile: src/*.hs
12 runghc Setup.hs configure --user --enable-executable-profiling
13 runghc Setup.hs build
14
15 hpc: src/*.hs
16 FLAGS="hpc" make
17
18 clean:
19 runghc Setup.hs clean
20 rm -f dist/
21 rm -f *.prof
22 rm -rf .hpc
23
24 test:
25 runghc -i"src" test/TestSuite.hs
26
27 src_html:
28 util/hscolour_srcs
29
30 # Neither 'haddock' nor 'hscolour' seem to work properly.
31 doc: src_html
32 runghc Setup.hs hscolour --executables
33 runghc Setup.hs haddock --internal \
34 --executables \
35 --hyperlink-source
36
37 SSH_USER=root@michael.orlitzky.com
38 PUBLIC_DOCDIR=/var/www/orlitzky.com/michael/public/spline3/
39 publish_doc: doc
40 rsync -avz -e ssh \
41 ./dist/doc/html/spline3/spline3 \
42 $(SSH_USER):$(PUBLIC_DOCDIR)
43
44 hlint:
45 hlint --ignore="Use camelCase" \
46 --ignore="Redundant bracket" \
47 --color \
48 src