When I run<div>sudo pacman -S xmonad</div><div><br></div><div>I get this error:</div><div><br></div><div><div>warning: xmonad-0.10-3 is up to date -- reinstalling</div><div>resolving dependencies...</div><div>looking for inter-conflicts...</div>
<div><br></div><div>Targets (1): xmonad-0.10-3</div><div><br></div><div>Total Installed Size:   6.82 MiB</div><div>Net Upgrade Size:       0.00 MiB</div><div><br></div><div>Proceed with installation? [Y/n] </div><div>(1/1) checking package integrity                                       [#######################################] 100%</div>
<div>(1/1) loading package files                                            [#######################################] 100%</div><div>(1/1) checking for file conflicts                                      [#######################################] 100%</div>
<div>(1/1) checking available disk space                                    [#######################################] 100%</div><div>ghc-pkg: cannot find package xmonad-0.10</div><div>error: command failed to execute correctly</div>
<div>(1/1) upgrading xmonad                                                 [#######################################] 100%</div><div>Reading package info from stdin ... done.</div><div>xmonad-0.10: Warning: haddock-interfaces: /usr/share/doc/xmonad-0.10/html/xmonad.haddock doesn't exist or isn't a file</div>
<div>xmonad-0.10: Warning: haddock-html: /usr/share/doc/xmonad-0.10/html doesn't exist or isn't a directory</div><div>xmonad-0.10: dependency "X11-1.5.0.1-23969a606024c8baf35a42f59a8da104" doesn't exist (use --force to override)</div>
<div>xmonad-0.10: dependency "mtl-2.0.1.0-db19dd8a7700e3d3adda8aa8fe5bf53d" doesn't exist (use --force to override)</div><div>xmonad-0.10: dependency "utf8-string-0.3.7-ca3bc669f78a10f8e42ef22439bcf83c" doesn't exist (use --force to override)</div>
<div>error: command failed to execute correctly</div></div><div><br></div><div>I get similar errors when I try to install haskell-http,mtl,network,parsec,random,text,transformers etc. These are all the packages that I installed previously, which worked fine and I somehow removed them. I don't know how I did that. They do not show up in ghc-pkg list. And that is the error that's being reported. From the above message I gather that these packages are not actually installed, pacman thinks they are and ghc thinks they are not. I should make pacman think they are not installed and reinstall them again.</div>
<div><br></div><div>Or it might be other way around. They <b>are</b> actually present (most probably indicated by the Net Upgrade Size: 0.00 MiB). Pacman could be right but those packages are not registered with ghc. Then I should find a way to register those packages with ghc. I think, the register.sh, unregister.sh in /usr/share/haskell folder allow me to do that. But before I realized this, I deleted the whole folder thinking it'd regenerate itself when I install them again. I know that was stupid.</div>
<div><br></div><div>I tried removing those packages using pacman -R haskell-http etc. They won't get removed. Same error.</div><div><br></div><div>I have one solution in mind, install cabal-install and install all those packages via cabal-install. Then, they'd get registered with ghc-pkg and removing them or reinstalling them via pacman would be possible. But I'm sure there's a better way. Can you tell me which one it is?</div>
<div><br></div><div>P.S: I think (I'm not sure) this situation got created when I ran pacman -S ghc after I installed all these pacakges. Could this be the problem or I'm talking nonsense?</div><div><br clear="all">
<div><br></div>-- <br>Warm Regards,<br><br>AbdulSattar Mohammed<br>
</div>