"undefined references" when using package

Sven Panne Sven.Panne at aedion.de
Sat Apr 17 13:48:39 EDT 2004


Jan Christiansen wrote:
> I try to generate a package out of some haskell sources. Everything looks to 
> work fine but when I try to compile a program using this package I get a 
> linking error. It reports "undefined reference" to seemingly everything that 
> is accessible form outside the package. I'm using ghc-6.2.1 and I would be 
> very grateful for a hint.

This sounds like missing dependencies in your package configuration file. Most
package mention e.g. at least the "base" package:

    package_deps   = [ "base" ]

Looking at the undefined references will probably help to figure out what should
be mentioned in your case. You don't have to do this transitively, BTW, GHC(i)
is cunning enough to do this itself, e.g. the "base" package depends on the "rts"
package, but you don't have to specify this in your configuration file.

Cheers,
    S.



More information about the Glasgow-haskell-users mailing list