Cabal: unable to update cabal-install to latest version

Created on 19 Nov 2017  路  8Comments  路  Source: haskell/cabal

First I installed cabal-install-2.0.0.0(latest version)

-$  cabal install cabal-install-2.0.0.0

Resolving dependencies...
Downloading HTTP-4000.3.8...
Downloading base16-bytestring-0.1.1.6...
Downloading cryptohash-sha256-0.11.101.0...
Configuring HTTP-4000.3.8...
Configuring base16-bytestring-0.1.1.6...
Downloading echo-0.1.3...
Configuring echo-0.1.3...
Downloading ed25519-0.0.5.0...
Downloading edit-distance-0.2.2.1...
Configuring cryptohash-sha256-0.11.101.0...
Building base16-bytestring-0.1.1.6...
Building HTTP-4000.3.8...
Building echo-0.1.3...
Downloading tar-0.5.0.3...
Building cryptohash-sha256-0.11.101.0...
Installed base16-bytestring-0.1.1.6
Configuring edit-distance-0.2.2.1...
Configuring tar-0.5.0.3...
Installed echo-0.1.3
Building edit-distance-0.2.2.1...
Building tar-0.5.0.3...
Configuring ed25519-0.0.5.0...
Installed cryptohash-sha256-0.11.101.0
Building ed25519-0.0.5.0...
Installed edit-distance-0.2.2.1
Installed ed25519-0.0.5.0
Installed tar-0.5.0.3
Downloading hackage-security-0.5.2.2...
Installed HTTP-4000.3.8
Configuring hackage-security-0.5.2.2...
Building hackage-security-0.5.2.2...
Installed hackage-security-0.5.2.2
Downloading cabal-install-2.0.0.0...
Configuring cabal-install-2.0.0.0...
Building cabal-install-2.0.0.0...
Installed cabal-install-2.0.0.0

Then on checking for version it remained same

$ cabal --version
cabal-install version 1.22.6.0
using version 1.22.5.0 of the Cabal library 

upon this I also update the Cabal Library to 2.0.0.2(latest version/) . But still this issue is persistent.

-$  cabal install Cabal-2.0.0.2
Resolving dependencies...
All the requested packages are already installed:
Cabal-2.0.0.2
Use --reinstall if you want to reinstall anyway.
user-question

All 8 comments

@Satyendra-IITR the new cabal executable is most likely installed into ${HOME}/.cabal/bin; it seems you're still getting the old executable.

@Satyendra-IITR What @hvr said, you probably need to add ~/.cabal/bin to $PATH and make sure it overrides the system bin path. I think that recent versions print a warning when that's not the case. What is the output of which cabal?

@23Skidoo it gives :

-$ which cabal
/usr/bin/cabal

@Satyendra-IITR Right, so the new version you installed should be in ~/.cabal/bin/. Try running ~/.cabal/bin/cabal --version to verify.

@Satyendra-IITR out of curiosity, on which Linux distro are you? what does lsb_release -a say?

@23Skidoo and @hvr Thanks, got it working :smile:

@hvr that command says:

No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 16.04.2 LTS
Release:    16.04
Codename:   xenial

@Satyendra-IITR ok, the reason I was asking is that I suspected you may be using Ubuntu (or another Linux distro for which there's cabal packages); and so you might be interested in my GHC+Cabal PPA https://launchpad.net/~hvr/+archive/ubuntu/ghc

Thanks again @hvr.

Was this page helpful?
0 / 5 - 0 ratings