[Haskell-cafe] difficulty building (some) TH packages with ghc-7.4.1

John Lato jwlato at gmail.com
Mon Mar 26 12:36:12 CEST 2012


Hello,

I've run into an odd problem when building certain packages that use
Template Haskell with GHC-7.4.1.  For example, RepLib:

$ cabal --version
cabal-install version 0.13.3
using version 1.14.0 of the Cabal library

$ cabal install -O2 -w ~/.ghc-7.4.1/bin/ghc RepLib --reinstall
Resolving dependencies...
Configuring RepLib-0.5.2...
Building RepLib-0.5.2...
Preprocessing library RepLib-0.5.2...
[ 1 of 12] Compiling Generics.RepLib.R ( Generics/RepLib/R.hs,
dist/build/Generics/RepLib/R.o )
[ 2 of 12] Compiling Generics.RepLib.R1 ( Generics/RepLib/R1.hs,
dist/build/Generics/RepLib/R1.o )
[ 3 of 12] Compiling Generics.RepLib.Derive (
Generics/RepLib/Derive.hs, dist/build/Generics/RepLib/Derive.o )
[ 4 of 12] Compiling Generics.RepLib.PreludeReps (
Generics/RepLib/PreludeReps.hs,
dist/build/Generics/RepLib/PreludeReps.o )
Loading package ghc-prim ... linking ... done.
Loading package integer-gmp ... linking ... done.
Loading package base ... linking ... done.
Loading package type-equality-0.1.0.2 ... linking ... done.
Loading package array-0.4.0.0 ... linking ... done.
Loading package deepseq-1.3.0.0 ... linking ... done.
Loading package containers-0.4.2.1 ... linking ... done.
Loading package pretty-1.1.1.0 ... linking ... done.
Loading package template-haskell ... linking ... done.
Loading package transformers-0.2.2.0 ... linking ... done.
Loading package mtl-2.0.1.0 ... linking ... done.
cabal: Error: some packages failed to install:
RepLib-0.5.2 failed during the building phase. The exception was:
ExitFailure 11

This is without library profiling enabled.  If I enable library
profiling, the unprofiled build is fine but the profiled build exits
with the same error, at the same location.

If I pass the "-v" argument to cabal-install, the package builds fine
with profiling disabled.  The "-v" flag makes no difference with
profiling enabled, although some packages (but not RepLib) work with
"-v2"

I haven't seen this with ghc-7.2.*, but I'm guessing this is some sort
of cabal-install bug.  Has anyone else witnessed anything like this?

Thanks,
John L.



More information about the Haskell-Cafe mailing list