From 642ab632aa71d4d258a1bdc3a0a279259b09043e Mon Sep 17 00:00:00 2001 From: Nathaniel Wesley Filardo Date: Wed, 10 Jul 2013 23:54:18 -0400 Subject: [PATCH] Add hpc coverage for self-tests Run with "make test-hpc" and then open dist/selftest-hpc-out/index.html for your viewing pleasure. --- Makefile | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/Makefile b/Makefile index 4048471..c4c2c6d 100644 --- a/Makefile +++ b/Makefile @@ -38,6 +38,7 @@ clean: examples/*.dyna.d \ examples/*.hist rm -rf test/*/*.out + rm -rf *.tix rm -f tags TAGS veryclean: clean rm -rf dist @@ -101,6 +102,27 @@ profbuild: -outputdir dist/pb \ -main-is $(MAINMOD) $(MAINFILE) +.PHONY: test-hpc +test-hpc: + mkdir -p dist/selftest-hpc + ghc -O0 -fhpc -isrc -idist/build/autogen --make \ + -o dist/selftest-hpc/dyna-selftests \ + -outputdir dist/selftest-hpc/dyna-selftests-tmp \ + -hpcdir dist/selftest-hpc/hpc \ + -main-is Dyna.Main.TestsDriver Dyna.Main.TestsDriver + # Remove any old .tix files + # (prevent "module mismatch with .tix/.mix file hash number") + rm -rf dyna-selftests.tix + # Run from top-level + dist/selftest-hpc/dyna-selftests + # Then move the mix and tix files out of the way + mv dyna-selftests.tix dist/selftest-hpc + # And last, generate markup + hpc markup \ + --destdir=dist/selftest-hpc-out \ + --hpcdir=dist/selftest-hpc/hpc \ + dist/selftest-hpc/dyna-selftests.tix + .PHONY: tags TAGS tags TAGS: hasktags -b src -- 2.50.1