[Haskell-cafe] FFI, C/C++ and undefined references

Malcolm Wallace malcolm.wallace at cs.york.ac.uk
Wed Jan 13 05:22:15 EST 2010


> But when I try to compile it (after having successfully compiled the  
> C code
> with g++), I get:
>
> $ ghc --make Main.hs

You are not telling ghc to link against the C/C++ code,  e.g.
     ghc --make Main.hs srilm.o

Regards,
     Malcolm



More information about the Haskell-Cafe mailing list