bos/criterion — Issue #7: Criterion fails to build with GHC 6.12.3
Author: sanketr
Created: 2012-01-04 04:38:57+00:00
State: open

Please see below for the error log on cabal install of criterion 0.6.0.0. The error doesn't happen with GHC 7.0.4. It will be very helpful to have criterion build on 6.12.3 as well because I am trying to pin-point the performance regression between 6.12.3 and 7.0.4 for my code. I am using RHEL 5 x86_64.

Error:
-------
Configuring criterion-0.6.0.0...
Preprocessing library criterion-0.6.0.0...
Building criterion-0.6.0.0...
[ 1 of 12] Compiling Paths_criterion ( dist/build/autogen/Paths_criterion.hs, dist/build/Paths_criterion.o )
[ 2 of 12] Compiling Criterion.Analysis.Types ( Criterion/Analysis/Types.hs, dist/build/Criterion/Analysis/Types.o )
[ 3 of 12] Compiling Criterion.Types ( Criterion/Types.hs, dist/build/Criterion/Types.o )
[ 4 of 12] Compiling Criterion.Measurement ( Criterion/Measurement.hs, dist/build/Criterion/Measurement.o )
[ 5 of 12] Compiling Criterion.Config ( Criterion/Config.hs, dist/build/Criterion/Config.o )
[ 6 of 12] Compiling Criterion.Monad ( Criterion/Monad.hs, dist/build/Criterion/Monad.o )
[ 7 of 12] Compiling Criterion.IO ( Criterion/IO.hs, dist/build/Criterion/IO.o )
[ 8 of 12] Compiling Criterion.Analysis ( Criterion/Analysis.hs, dist/build/Criterion/Analysis.o )
[ 9 of 12] Compiling Criterion.Environment ( Criterion/Environment.hs, dist/build/Criterion/Environment.o )
[10 of 12] Compiling Criterion.Report ( Criterion/Report.hs, dist/build/Criterion/Report.o )

Criterion/Report.hs:73:24:
No instance for (MonadIO Criterion)
arising from a use of `liftIO' at Criterion/Report.hs:73:24-29
Possible fix: add an instance declaration for (MonadIO Criterion)
In the first argument of `($)', namely `liftIO'
In the expression:
liftIO
$ do { tpl <- loadTemplate
[".", templateDir] (fromLJ cfgTemplate cfg);
L.writeFile name =<< formatReport reports tpl }
In a case alternative:
Last (Just name)
-> liftIO
$ do { tpl <- loadTemplate [".", ....] (fromLJ cfgTemplate cfg);
L.writeFile name =<< formatReport reports tpl }
cabal: Error: some packages failed to install:
criterion-0.6.0.0 failed during the building phase. The exception was:
ExitFailure 1