From e5035ed42a2088b68e54d555e29ca0fbec55ed0d Mon Sep 17 00:00:00 2001 From: Simon Michael Date: Wed, 10 Dec 2008 20:46:18 +0000 Subject: [PATCH] build and use an easy ./bench binary --- Makefile | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index 2dfd09489..0dbc9112c 100644 --- a/Makefile +++ b/Makefile @@ -1,3 +1,4 @@ +# executables for "make bench". prepend ./ to these if not in $PATH BENCHEXES=hledger ledger BUILD=ghc --make hledger.hs -o hledger -O @@ -34,11 +35,13 @@ profile: cp simple.prof profs/$(TIME).prof cat simple.prof -BENCHITERATIONS=2 # run performance benchmarks and save results in profs -# prepend ./ to executables if not in $PATH -bench: - tools/bench.hs bench.tests $(BENCHITERATIONS) $(BENCHEXES) | tee profs/`date +%Y%m%d%H%M%S`.bench +bench: buildbench + ./bench $(BENCHEXES) | tee profs/`date +%Y%m%d%H%M%S`.bench + +buildbench: + ghc --make tools/bench.hs + rm -f bench; ln -s tools/bench VERSION=`grep 'versionno =' Options.hs | perl -pe 's/.*"(.*?)"/\1/'` release: