hledger/Makefile

54 lines
1.0 KiB
Makefile
Raw Normal View History

2007-07-04 07:33:08 +04:00
BUILD=ghc --make hledger.hs -o hledger -prof -auto-all
BUILDOPT=ghc --make hledger.hs -o hledgeropt -O2
PROFILE=./hledger -s balance +RTS -p
2007-05-02 06:50:10 +04:00
TIME=`date +"%Y%m%d%H%M"`
2007-02-11 02:25:48 +03:00
build: Tags
2007-05-02 06:50:10 +04:00
$(BUILD)
2007-07-04 13:28:07 +04:00
buildopt opt: clean
2007-07-04 07:33:08 +04:00
$(BUILDOPT)
2007-07-02 20:31:47 +04:00
2007-07-04 07:33:08 +04:00
profile: build
$(PROFILE)
mv hledger.prof profs/$(TIME).prof
2007-07-03 09:42:43 +04:00
rm -f last.prof
2007-07-04 07:33:08 +04:00
ln -s profs/$(TIME).prof last.prof
head -20 profs/$(TIME).prof >simple.prof
2007-07-03 13:11:03 +04:00
cat simple.prof
./simplifyprof.hs <last.prof >>simple.prof
2007-05-02 06:50:10 +04:00
2007-07-04 07:33:08 +04:00
xprofile: build
$(PROFILE) -x
mv hledger.prof profs/$(TIME).xprof
ghcprof profs/$(TIME).xprof
2007-07-04 06:23:37 +04:00
#LEDGER=test.dat
compare: build
2007-07-04 06:23:37 +04:00
rm -f 1 2
ledger -s balance >1
ledger register >>1
2007-07-04 13:28:07 +04:00
ledger print >>1
./hledger -s balance >2
./hledger register >>2
./hledger print >>2
2007-07-04 06:23:37 +04:00
diff 1 2
haddock:
haddock -h -o doc *.hs
2007-03-10 05:07:11 +03:00
overview:
2007-07-03 13:11:03 +04:00
@./overview.hs Types.hs | tee OVERVIEW
2007-03-10 02:21:49 +03:00
loc:
@darcs trackdown 'find . -name "*hs" |xargs wc -l |echo OUTPUT `tail -1`; false' |ruby -nae'puts $$F[1] if /^OUTPUT/'
2007-02-09 06:32:07 +03:00
Tags:
hasktags *hs
2007-02-09 06:17:18 +03:00
clean:
2007-07-04 07:33:08 +04:00
rm -f *.o *.hi *~ 1 2
2007-02-09 06:17:18 +03:00
Clean: clean
2007-07-04 07:33:08 +04:00
rm -f hledger hledgeropt overview TAGS tags