Skip to content

Amend non-reinstallable packages list #10087

Open
@adamgundry

Description

cabal-install maintains a list of nonReinstallablePackages, preventing certain packages being reinstalled by the user. This list needs some updates:

The list of non-reinstallable packages does not currently depend on the compiler version. Really it should; is there an easy way to achieve this?

-- | The set of non-reinstallable packages includes those which cannot be
-- rebuilt using a GHC installation and Hackage-published source distribution.
-- There are a few reasons why this might be true:
--
-- * the package overrides its unit ID (e.g. with ghc's @-this-unit-id@ flag),
-- which can result in multiple indistinguishable packages (having potentially
-- different ABIs) with the same unit ID.
--
-- * the package contains definitions of wired-in declarations which tie
-- it to a particular compiler (e.g. we can't build link against
-- @base-4.18.0.0@ using GHC 9.6.1).
--
-- * the package does not have a complete (that is, buildable) source distribution.
-- For instance, some packages provided by GHC rely on files outside of the
-- source tree generated by GHC's build system.
nonReinstallablePackages :: [PackageName]
nonReinstallablePackages =
[ mkPackageName "base"
, mkPackageName "ghc-bignum"
, mkPackageName "ghc-prim"
, mkPackageName "ghc"
, mkPackageName "integer-gmp"
, mkPackageName "integer-simple"
, mkPackageName "template-haskell"
]

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions