diff options
author | John MacFarlane <jgm@berkeley.edu> | 2012-07-26 09:18:17 -0700 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2012-07-26 09:19:40 -0700 |
commit | c414a08bcf4a4ae6c9c8007e27b87122217cdcee (patch) | |
tree | 3cbe1dd60927cb361c29ea2f8d581cc669b9a0b1 /pandoc.cabal | |
parent | 45e4c123a45b83d666088967c25b91cf9bb5db72 (diff) | |
download | pandoc-c414a08bcf4a4ae6c9c8007e27b87122217cdcee.tar.gz |
Integrated benchmark into cabal.
Can now do:
cabal configure --enable-benchmarks && cabal build
cabal bench --benchmark-option='markdown' --benchmark-option='-s 20'
Diffstat (limited to 'pandoc.cabal')
-rw-r--r-- | pandoc.cabal | 21 |
1 files changed, 19 insertions, 2 deletions
diff --git a/pandoc.cabal b/pandoc.cabal index de8381dfe..6499abb4c 100644 --- a/pandoc.cabal +++ b/pandoc.cabal @@ -96,8 +96,6 @@ Extra-Source-Files: -- generated man pages (produced post-build) man/man1/pandoc.1, man/man5/pandoc_markdown.5, - -- benchmarks - Benchmark.hs, -- tests tests/bodybg.gif, tests/docbook-reader.docbook @@ -427,3 +425,22 @@ Executable test-pandoc Default-Language: Haskell98 Default-Extensions: CPP, TemplateHaskell, QuasiQuotes +benchmark benchmark-pandoc + Type: exitcode-stdio-1.0 + Main-Is: benchmark-pandoc.hs + Hs-Source-Dirs: benchmark + if impl(ghc >= 6.10) + Build-depends: base >= 4 && < 5, syb >= 0.1 && < 0.4 + else + Build-depends: base >= 3 && < 4 + Build-Depends: pandoc, + criterion >= 0.5 && < 0.7, + json >= 0.4 && < 0.6 + if impl(ghc >= 7.0.1) + Ghc-Options: -O2 -rtsopts -Wall -fno-warn-unused-do-bind -dno-debug-output + else + if impl(ghc >= 6.12) + Ghc-Options: -O2 -Wall -fno-warn-unused-do-bind -dno-debug-output + else + Ghc-Options: -O2 -Wall + Default-Language: Haskell98 |