getLinkDeps panic
I am working on a project which uses mutually recursive modules and Template Haskell. Since "ghc --make" does not seem to figure out the dependencies properly in this case (see bug #1012 (closed)) I gave Cabal's make backend a try without luck (I'm stuck again).
The compilation results in:
/usr/local/bin/ghc -package-name ForSyDe-0.1 -hide-all-packages -i -idist/build/autogen -idist/build -isrc -Idist/build -odir dist/build -hidir dist/build -stubdir dist/build -package packedstring-0.1.0.0 -package base-3.0.1.0 -package regex-posix-0.72.0.2 -package mtl-1.1.0.0 -package pretty-1.0.0.0 -package template-haskell-2.2.0.0 -O -Wall -fno-warn-name-shadowing -fno-warn-orphans -idist/build -c src/ForSyDe/Process/SynchProc.hs -o dist/build/ForSyDe/Process/SynchProc.o -ohi dist/build/ForSyDe/Process/SynchProc.hi
Loading package base ... linking ... done.
Loading package pretty-1.0.0.0 ... linking ... done.
Loading package array-0.1.0.0 ... linking ... done.
Loading package packedstring-0.1.0.0 ... linking ... done.
Loading package containers-0.1.0.1 ... linking ... done.
Loading package template-haskell ... linking ... done.
Loading package mtl-1.1.0.0 ... linking ... done.
Loading package bytestring-0.9.0.1 ... linking ... done.
Loading package regex-base-0.72.0.1 ... linking ... done.
Loading package regex-posix-0.72.0.2 ... linking ... done.
ghc-6.8.2: panic! (the 'impossible' happened)
(GHC version 6.8.2 for i386-apple-darwin):
getLinkDeps No iface for ForSyDe-0.1:ForSyDe.System.SysDef
Please report this as a GHC bug: http://www.haskell.org/ghc/reportabug
make: *** [dist/build/ForSyDe/Process/SynchProc.o] Error 1
However, the interface file is available to ghc:
$ ls -l dist/build/ForSyDe/System/SysDef.hi
-rw-r--r-- 1 fons staff 2225 2 ene 18:13 dist/build/ForSyDe/System/SysDef.hi
Sorry, but I couldn't narrow down the problem. To reproduce it, simply download my library (http://homepage.mac.com/alfonso.acosta/.Public/ForSyDe.tgz ) and build using Cabal's make backend:
$ tar -xvzf ForSyDe.tgz; cd ForSyDe; ./Setup.hs configure; ./Setup.hs makefile; make
Curiously enough, building the library itself does not work but loading a test in ghci, works perfectly well and builds the whole library without problems:
$ cd ForSyDe/examples/ ; ghci -i../src ParAddFour.hs
GHCi, version 6.8.2: http://www.haskell.org/ghc/ :? for help
Loading package base ... linking ... done.
... (vompilation skipped)
Ok, modules loaded: ForSyDe, ParAddFour, ForSyDe.AbsentExt, Language.Haskell.TH.Lift, ForSyDe.Vector, ForSyDe.Backend, ForSyDe.Backend.Simulate, Language.Haskell.TH.TypeLib, ForSyDe.Process, ForSyDe.Process.ProcVal, ForSyDe.ForSyDeErr, ForSyDe.ForSyDeErr, ForSyDe.Netlist, ForSyDe.Process.ProcFun, ForSyDe.Process.ProcFun, Language.Haskell.TH.LiftInstances, ForSyDe.System, ForSyDe.System.SysDef, ForSyDe.System.SysDef, ForSyDe.OSharing, ForSyDe.OSharing.UDynamic, ForSyDe.System.SysFun, ForSyDe.Signal, ForSyDe.Netlist.Traverse, ForSyDe.System.Instantiate, ForSyDe.Process.SynchProc.
*ParAddFour>
It is a major blocker for the project (I have been stuck for days). I hope you find appropiate that I tagged it as such.
Trac metadata
Trac field | Value |
---|---|
Version | 6.8.2 |
Type | Bug |
TypeOfFailure | OtherFailure |
Priority | normal |
Resolution | Unresolved |
Component | Compiler |
Test case | |
Differential revisions | |
BlockedBy | |
Related | |
Blocking | |
CC | |
Operating system | Unknown |
Architecture | Unknown |