Building GHC on Windows

Felix Martini fmartini at gmail.com
Tue Feb 17 12:08:30 EST 2009


Hi all,

Simon Marlow has recently posted a patch that adds Unicode support to
Handle I/O. He mentioned that it didn't work yet on Windows so i was
thinking of looking at the source code to see how the new Unicode
support works and perhaps try to make it work on Windows.

I have built GHC from source in the past on Windows and the process
was cumbersome compared to building it on Linux. But i was curious to
see if it has gotten easier.

After reading the Wiki i decided to get the source with Git as Darcs
was slow with remote downloads. Ok, that was a lot quicker than
before! Let's see, i need to run sync-all to get the core libraries. I
remember that i used to use darcs-all so it must be a new script.
Sync-all doesn't have an extension so i probably need to run it with
msys. That doesn't work, somehow my msys environment does not find
git. So let's try the Git Bash environment which also uses msys (and
does not have bash). Now i get a cryptic error: "at ./sync-all line
99, <IN> line 19." It seems the script cannot determine the default
remote repo. The top line shows that it is a Perl script and i don't
know Perl enough to see what is wrong. I have Perl installed on this
Windows pc so let's try to run the script directly. That doesn't work
either: the Perl script wants to use grep and sed.

All this is likely trivial to fix but at the same time these little
roadblocks may also explain why few developers on Windows contribute
code to GHC and Haskell.

Regards,
Felix


More information about the Glasgow-haskell-users mailing list