GHC Error in linker "undeined reference"
Esa Ilari Vuokko
eivuokko at gmail.com
Sat Aug 12 16:39:26 EDT 2006
Hi,
On 8/12/06, Johan Grönqvist <johan.gronqvist at gmail.com> wrote:
> import Control.Monad.State
> import Control.Monad.ST
> import Data.Array.ST
> import Data.List
Control.Monad.State is from package mtl, the other modules are part
of the base package, I think.
> ubuntu at ubuntu:~/haskell/Forth$ ghc forth.lhs
You need to tell ghc that you want to link package mtl.
ghc -package mtl forth.lhs
or more automatic
ghc --make forth.lhs
The packages you can import without any additional options are
the packages "ghc-pkg list" shows as visible. But without --make, or
explicitly telling, ghc doesn't know which packages to link with.
HTH,
--Esa
More information about the Glasgow-haskell-users
mailing list