An independent subset of bonded kits

Given the set of cabal packages, is there a way to automatically compute a subset of independent packages? In other words, a subset of packages that will be sufficient to install them.

For [network,parsec] answer is [network] because it is network dependent on parsec .

For [network,containers] answer is [network,containers] , because:

  • network independent of containers
  • all network dependencies are containers independent
  • containers independent of network
  • all containers dependencies are network independent

It is easy to find the answer to 2 packages. What is really interesting is finding an independent set for [containers, directory, filepath, lens, xml, http-conduit, regex-posix, monad-control, unordered-containers, glib, hashable, hspec, split, aeson, attoparsec, stm, QuickCheck] .




From the answer, I expect some function based on the cabal library, for example ∷ [Packages] → IO [Packages] .

+48
haskell cabal
03 Mar. '13 at 14:35
source share
1 answer

Cabal is moving to a more NPM-like model, which will greatly simplify dependency resolution. Each installed package will store a local copy of its dependencies, trading small disk space for a headache when installing several global packages with the requirements of mutually exclusive versions of the package.

In this model, the subset of packages required to install the package set == that is installed. Although one of them may be dependent on the other, each installed copy will keep its own local copy of its dependencies, so Cabal will no longer consider the dependency set in this way.

+1
May 15 '13 at 17:42
source share



All Articles