[Haskell-cafe] Why does cabal unnecessarily reinstall dependencies?

Ivan Lazar Miljenovic ivan.miljenovic at gmail.com
Mon Nov 22 16:36:53 EST 2010

On 23 November 2010 08:26, Martijn van Steenbergen
<martijn at van.steenbergen.nl> wrote:
> Hello cafe,
> When I want to locally install my own package through "cabal install" it
> tries to reinstall dependencies convertible-, HDBC- and
> HDBC-mysql-0.6.3 even though they are already installed (and work fine). Why
> does it do this?

1) Does "ghc-pkg check" complain about them?  If so, it will rebuild them.

2) Do you mean it rebuilds the same version or a different/older version?

3) Did you build those packages with any compile-time flags,
constraints, etc.?  If so, I believe cabal-install defaults to wanting
to rebuild them with the default settings.

I believe that if you want to stop cabal-install from rebuilding
non-broken packages, that unpacking what you want to install and then
running "cabal install" within that directory (as opposed to doing
"cabal install foo") is meant to work.

Ivan Lazar Miljenovic
Ivan.Miljenovic at gmail.com

More information about the Haskell-Cafe mailing list