Hey all, I'm trying to compile JHC on OS X. However, when I do a 'make jhc', I got the following error:
src/FlagDump.hs Use of uninitialized value in hash element at ./utils/opt_sets.prl
src/FlagOpts.hs Use of uninitialized value in hash element at ./utils/opt_sets.prl
make jhc perl ./utils/opt_sets.prl -n src/FlagDump.flags src/FlagDump.flags line 44, <> line 84. perl ./utils/opt_sets.prl -n src/FlagOpts.flags src/FlagOpts.flags line 44, <> line 45. Use of uninitialized value in hash element at ./utils/opt_sets.prl line 44, <> line 45. happy -a -g -c src/FrontEnd/HsParser.y -o src/FrontEnd/HsParser.hs unused rules: 2 shift/reduce conflicts: 73 reduce/reduce conflicts: 23 sed -e 's/^{-# OPTIONS[A-Z_]*/{-# OPTIONS_GHC -w /' -i src/FrontEnd/ HsParser.hs sed: -i may not be used with stdin make: *** [src/FrontEnd/HsParser.hs] Error 1 make: *** Deleting file `src/FrontEnd/HsParser.hs'
I fixed that by adding the extension to sed -i (I've attached a patch for that, my sendmail is broken). For future reference: I had some problems installing readline (using fink's readline). There's a thread [1] on haskell-café that solves that. After changing the line and installing readline, it started compiling. After a while, the compiler stopped with:
src/E/Subst.hs:143:22: No instance for (T.Traversable (Lit TVr))
This was because I had an old version of Drift installed. I didn't see an error, it should probably fail as early as possible and notify me that I had an old version that didn't support deriving Traversable. Finally, JHC was compiled! When compiling the libraries, however, it failed again:
lib/containers/Data/Sequence.hs:312:16: Parse error make[1]: *** [containers-0.2.0.hl] Error 1
Is somebody already working on that? If not, I'd be happy to dive in and fix it. (BTW, the culprit is the following line:)
{-# SPECIALIZE INLINE deep :: Digit (Elem a) -> FingerTree (Node (Elem a)) -> Digit (Elem a) -> FingerTree (Elem a) #-}
Thanks, -chris [1]: http://www.haskell.org/pipermail/libraries/2009-May/011597.html