FWIW, I used to employ a combination of environment vars and registry entries (for file associations) on Windows in order to be able to work with multiple GHC versions.  The environment vars (e.g. for PATH or LIB inclusion) would all depend on a GHC_HOME var, which could be redefined to point to the GHC installation du jour.

I am not sure how much common structure there would be among installations of GHC, NHC, HUGS, etc., but maybe the same thing could still work, possibly with some tweaks.


Cheers,

Dinko


On 3/15/07, Sven Panne <sven.panne@aedion.de> wrote:
On Thursday 15 March 2007 10:56, Malcolm Wallace wrote:
> [...] If you install hmake, and change 'runhaskell' to runhs, it works.

This reminds me of something, at least for the Linux world: No Haskell
compiler/interpreter should directly install 'runhaskell'. Instead of that,
it should only directly install runghc, runhugs, runnhc, ... and use
update-alternatives (or a similar technology for that platform) to inform the
native package system that there is a new alternative for 'runhaskell'.
Similar reasoning holds for cpphs, hsc2hs and friends. I'll update the .spec
files accordingly soon.

Doing it that way, the local sysadmin has the choice to configure which
Haskell implementation is the default and several versions of the same
implementation could be installed side by side.

I don't have a clue how to do this correctly for Mac OS X and Windows, though.
And 'runhs' is actually not a very good name to run nhc98, runnhc or runnhc98
would be much better IMHO.

Cheers,
   S.