What's the smoothest way to update haskell platform to latest?
Asked Answered
C

4

19

I'm on OSX 10.6 and I have platform 2010.2.0.0 currently. Should I just install 2011.2.0.1 on top or is there an update mechanism that will be smoother?

Cloddish answered 25/9, 2011 at 16:42 Comment(0)
E
7

I've definitely had bumpy upgrade experiences with the Haskell Platform. If you have enough trouble that you just want to wipe the thing and start fresh (you wouldn't be the first!), take a look here:

Everywhere that GHC/Haskell Platform installs

Erida answered 26/9, 2011 at 1:11 Comment(0)
F
5

As far as I know there is no update mechanism. And I have never had any trouble with just installing one platform version on top of the other on OSX.

Fawnia answered 25/9, 2011 at 19:32 Comment(1)
Thanks. I'll just go ahead and do that then.Cloddish
K
2

I come from the future (06/2013) and I just had to nuke my entire installation of the haskell platform in order to successfully install a newer. So... there's still no smooth way of upgrading. (At least in OS X)

Kurgan answered 11/6, 2013 at 4:13 Comment(1)
For any one wondering... First I tried to install one version on top of an older one, but I was having trouble installing libraries through cabal.Fulminant
B
2

Whether you need to nuke the existing platform depends on where cabal is configured to install packages.

On Mac OS X, the supplied cabal-install is modified to create a config which separates packages by GHC version. If that's the config you used, you can just install the Haskell Platform on top of the old one.

install-dirs user
  prefix: /Users/pgiarrusso/Library/Haskell/$compiler/lib/$pkgid
-- [...]
install-dirs global
  prefix: /Library/Haskell/$compiler/lib/$pkgid

Installation-specific binaries, like the ones from gtk2hs-buildtools, are only separated with a configuration like the above. As far as I can tell, at least the actual package register (in ~/.ghc/$GHC_VERSION, used by ghc-pkg and cabal) is instead always per-GHC-version. The config generated by a vanilla cabal-install (from Hackage) does not take such precautions.

install-dirs user
  -- prefix: /Users/pgiarrusso/.cabal
[...]
install-dirs global
  -- prefix: /usr/local

If you have such a config, I expect you're going to get trouble unless you remove at least the data in ~/.cabal, and also the binaries in /usr/local from the old Haskell Platform — but don't nuke the whole directory, since /usr/local is often used for installing other software!

The default config is only generated when no config exists, so to update the config you need to move away the existing one.

Bicycle answered 14/8, 2013 at 9:57 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.