Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to overcome [cabal: error while loading shared libraries:] error on arch linux?

I had some problems a while back trying to use cabal, so I reinstalled ghc (from 8.6.3) to 8.6.4.

When I try to use cabal (after it is uninstalled completely) I still get the below error, but can't see the file mentioned in when using fzf from the root directory. fzf from root

[warrick@warrick-pc ~]$ cabal
cabal: error while loading shared libraries: libHSzip-archive-0.3.3-FtEZ8cVpsWW1rhccfBNhic-ghc8.6.3.so: cannot open shared object file: No such file or directory

I have completely removed ~/.cabal but still don't have any clue how cabal is still being called from somewhere even though I have unistalled it. If I reinstall it and use cabal I get the same error message.


2 Answers

I had similar problems and ended up reinstalling the specific Haskell libraries. E.g, for libHSdlist-0.8.0.6-CQRMCGRgL5B3ZxhntX4iOr-ghc8.6.4.so I'd run pacman -S haskell-dlist. So in your case, you'd want to run pacman -S haskell-zip-archive

like image 139
ahstro Avatar answered Mar 12 '26 18:03

ahstro


I had a related error but with pandoc. I installed it using yay -S pandoc and when I removed and reinstalled it using pacman -S pandoc the error disappeared.

like image 33
Mohammed Samir Avatar answered Mar 12 '26 16:03

Mohammed Samir