problems encountered installing/upgrading Cabal

I want to install Cabal library 1.6.0.2 on OSX 10.4.11. Unfortunately, none of my attempts so far appear to have worked. I already had 1.4.0.1 but it wouldn't upgrade when running "cabal upgrade", it just hangs. iainb$ cabal --v cabal-install version 0.5.1 using version 1.4.0.1 of the Cabal library first attempt: iainb$ darcs get http://darcs.haskell.org/cabal-install iainb$ sudo sh bootstrap.sh Setup: At least the following dependencies are missing: Cabal >=1.7.2 && <1.9 Error during cabal-install bootstrap: Configuring the cabal-install package failed second attempt; I downloaded the tarball from http://www.haskell.org/ cabal/release/cabal-1.6.0.2/Cabal-1.6.0.2.tar.gz: iainb$ cd Cabal-1.6.0.2/ iainb$ sudo runhaskell Setup configure --prefix=/usr/local/ iainb$ sudo runhaskell Setup build iainb$ sudo runhaskell Setup install Installing library in /usr/local/lib/Cabal-1.6.0.2/ghc-6.8.3 Registering Cabal-1.6.0.2... Reading package info from "dist/installed-pkg-config" ... done. Saving old package config file... done. Writing new package config file... done. iainb$ cabal --v cabal-install version 0.5.1 using version 1.4.0.1 of the Cabal library If I run "ghc-pkg list" then it displays: /usr/local/lib/ghc-6.8.3/package.conf: Cabal-1.2.3.0, Cabal-1.6.0.2, ... /Users/iainb/.ghc/i386-darwin-6.8.3/package.conf: Cabal-1.6.0.2, ... I don't seem to understand what I'm supposed to do, or why 1.4.0.1 is the lib being used when it's not in the pkg list. Does anyone know how I can get cabal-install to use the new library? Any help is much appreciated. Iain

Iain Barnett wrote:
I want to install Cabal library 1.6.0.2 on OSX 10.4.11. Unfortunately, none of my attempts so far appear to have worked. I already had 1.4.0.1 but it wouldn't upgrade when running "cabal upgrade", it just hangs.
iainb$ cabal --v cabal-install version 0.5.1 using version 1.4.0.1 of the Cabal library
first attempt:
iainb$ darcs get http://darcs.haskell.org/cabal-install iainb$ sudo sh bootstrap.sh
Setup: At least the following dependencies are missing: Cabal >=1.7.2 && <1.9
The darcs version relies on an unreleased version of the Cabal library. (If you want to go that route, it's available from http://darcs.haskell.org/Cabal/ )
second attempt; I downloaded the tarball from http://www.haskell.org/cabal/release/cabal-1.6.0.2/Cabal-1.6.0.2.tar.gz:
Good so far.
iainb$ cd Cabal-1.6.0.2/ iainb$ sudo runhaskell Setup configure --prefix=/usr/local/ iainb$ sudo runhaskell Setup build iainb$ sudo runhaskell Setup install Installing library in /usr/local/lib/Cabal-1.6.0.2/ghc-6.8.3 Registering Cabal-1.6.0.2... Reading package info from "dist/installed-pkg-config" ... done. Saving old package config file... done. Writing new package config file... done.
iainb$ cabal --v cabal-install version 0.5.1 using version 1.4.0.1 of the Cabal library
That's the library cabal-install was compiled and linked against. You'll have to reinstall cabal-install as well. Does cabal install --global cabal-install work? Btw, if you have installed cabal-install with --user (which is the default), the binary will be in ~/.cabal/bin , which you can add to your PATH. Otherwise, pick up the latest release from http://hackage.haskell.org/package/cabal-install and compile it manually.
If I run "ghc-pkg list" then it displays: /usr/local/lib/ghc-6.8.3/package.conf: Cabal-1.2.3.0, Cabal-1.6.0.2, ... /Users/iainb/.ghc/i386-darwin-6.8.3/package.conf: Cabal-1.6.0.2, ...
That part looks good. Note that you have two installations of the Cabal library, one global and one user installation. HTH, Bertram

On Sun, 2009-06-21 at 12:45 +0100, Iain Barnett wrote:
first attempt:
iainb$ darcs get http://darcs.haskell.org/cabal-install iainb$ sudo sh bootstrap.sh
Just switch to the released version and that should work fine (or if you really really want a darcs version then use the stable branch rather than the head branch).
I don't seem to understand what I'm supposed to do, or why 1.4.0.1 is the lib being used when it's not in the pkg list.
Programs built with ghc are statically linked. So it can still be using the old lib even after that lib has been removed.
Does anyone know how I can get cabal-install to use the new library?
It's not dynamically linked, you need to build cabal-install against the new library (which is what will happen when you run the bootstrap.sh). Duncan
participants (3)
-
Bertram Felgenhauer
-
Duncan Coutts
-
Iain Barnett