ghc-6.0.1 --make -O (linking errors)

Hi all, I recently switched to ghc 6.0.1 running on a debian linux box. When compiling a program using ghc --make -O or ghc --make -O2 I get lots of errors while linking. The linker concerns about undefined references to Data.FiniteMap, which I frequently use. For example, the linker says: ../Options.o(.text+0xc0d): In function `s4m5T_ret': : undefined reference to `DataziFiniteMap_lvl4_closure' Without optimizing my code, doing a plain ghc --make everything goes fine. Similarly, compiling the same program with the older ghc 6.0 I do not get any linking errors, whether I optimize or not. Any ideas, how I can get rid of the linking errors, except for switching back to ghc 6.0? Best Regards, Jan

On Thu, Jul 31, 2003 at 08:55:01AM +0200, Jan Scheffczyk wrote:
Hi all,
I recently switched to ghc 6.0.1 running on a debian linux box.
When compiling a program using ghc --make -O or ghc --make -O2 I get lots of errors while linking. The linker concerns about undefined references to Data.FiniteMap, which I frequently use.
If you are not already using them then you could try the debs from the Haskell Experimental repository. Both stable and unstable debs are available (unfortunately they are awaiting manual intervention before going into the Debian archive as there are a couple of new package names): deb http://www.syntaxpolice.org/haskell-experimental/ stable/ deb http://www.syntaxpolice.org/haskell-experimental/ unstable/ If these suffer from the same problem then please let me know, and if possible give me some sources that show it. Thanks Ian

Hi Ian,
If you are not already using them then you could try the debs from the Haskell Experimental repository. Both stable and unstable debs are available (unfortunately they are awaiting manual intervention before going into the Debian archive as there are a couple of new package names):
Thanks. We have found the error. In my Makefile I had added an explicit library search path (via -L) where ghc 6.0 libs are installed. Changing the path to the ghc 6.0.1 libs directory made ghc compile my program, as expected :-)). So it was absolutely MY mistake and not ghc's. Best regards, Jan
participants (2)
-
Ian Lynagh
-
Jan Scheffczyk