2
votes

I just upgraded to ghc 7.10.1 and whenever I try use cabal-install I run into the following error:

ghc: ghc no longer supports single-file style package databases (dist/package.conf.inplace) use 'ghc-pkg init' to create the database with the correct format.

How do I fix this?

2
I think that means that your version of cabal is too old for GHC 7.10. - Michael Snoyman
Try to cabal install cabal-install and then make sure new version is on the path. You can check version of cabal this way: cabal --version. - Mark Karpov
Don't forget to refresh package list cabal update. - Mark Karpov
I thought this was the error as well but I cant update my cabal because when I run cabal install cabal-install I get the same error as above - Kyle McKean
Try to move/delete ~/.cabal and ~/.ghc, then run again cabal install cabal-install - sinelaw

2 Answers

0
votes

If you are on Mac OS X and are using homebrew it may be that you installed Cabal through haskell-platform package, which is outdated with no direct upgrade path.

You should uninstall haskell-platform and reinstall Cabal using the cabal-install package.

0
votes

It could well be you have a newer cabal on your path but can't find it because the old one shadows it. So looking for where cabal may help you resolve that. Barring that, you can download a newer cabal binary from the cabal homepage.