Add GHCJS support to the Simple build infrastructure

This also restructures some of the GHC, HcPkg and Haddock modules
to make it easier to share the code between multiple GHC-derived
compilers.