Failed to install Cabal-1.20.0.2

I am getting this error when I try to install Cabal-1.20.0.2:

$ cabal install Cabal-1.20.0.2.tar.gz 
Resolving dependencies...
Configuring Cabal-1.20.0.2...
Failed to install Cabal-1.20.0.2
Last 10 lines of the build log ( /home/yonutix/.cabal/logs/Cabal-1.20.0.2.log ):
cabal: Error: some packages failed to install:
Cabal-1.20.0.2 failed during the configure step. The exception was:
user error (
/tmp/Cabal-1.20.0.2-11804/Cabal-1.20.0.2/Distribution/Simple/Utils.hs:386:31:
Warning:
In the use of β€˜runGenProcess_’
(imported from System.Process.Internals):
Deprecated: "Please do not use this anymore, use the ordinary
'System.Process.createProcess'. If you need the SIGINT handling, use
delegate_ctlc = True (runGenProcess_ is now just an imperfectly emulated stub
that probably duplicates or overrides your own signal handling)."
/usr/bin/ld: cannot find -lgmp
collect2: error: ld returned 1 exit status
)

      

I need to install this package because it depends on how it is installed.

What could be the problem? Thank!

+3


source to share


1 answer


The problem is indicated by this part of the log file:

/usr/bin/ld: cannot find -lgmp

      



ghc cannot find libgmp. Most likely the fix is ​​to install a package libgmp-dev

like. under Ubuntu:

sudo apt-get install libgmp-dev

      

+8


source







All Articles