Copyright | (c) The University of Glasgow 2004 |
---|---|
Maintainer | libraries@haskell.org |
Portability | portable |
Safe Haskell | None |
Language | Haskell98 |
This is the information about an installed package that
is communicated to the ghc-pkg
program in order to register
a package. ghc-pkg
now consumes this package format (as of version
6.4). This is specific to GHC at the moment.
The .cabal
file format is for describing a package that is not yet
installed. It has a lot of flexibility, like conditionals and dependency
ranges. As such, that format is not at all suitable for describing a package
that has already been built and installed. By the time we get to that stage,
we have resolved all conditionals and resolved dependency version
constraints to exact versions of dependent packages. So, this module defines
the InstalledPackageInfo
data structure that contains all the info we keep
about an installed package. There is a parser and pretty printer. The
textual format is rather simpler than the .cabal
format: there are no
sections, for example.
- data InstalledPackageInfo = InstalledPackageInfo {
- sourcePackageId :: PackageId
- installedUnitId :: UnitId
- compatPackageKey :: String
- license :: License
- copyright :: String
- maintainer :: String
- author :: String
- stability :: String
- homepage :: String
- pkgUrl :: String
- synopsis :: String
- description :: String
- category :: String
- abiHash :: AbiHash
- exposed :: Bool
- exposedModules :: [ExposedModule]
- hiddenModules :: [ModuleName]
- trusted :: Bool
- importDirs :: [FilePath]
- libraryDirs :: [FilePath]
- dataDir :: FilePath
- hsLibraries :: [String]
- extraLibraries :: [String]
- extraGHCiLibraries :: [String]
- includeDirs :: [FilePath]
- includes :: [String]
- depends :: [UnitId]
- ccOptions :: [String]
- ldOptions :: [String]
- frameworkDirs :: [FilePath]
- frameworks :: [String]
- haddockInterfaces :: [FilePath]
- haddockHTMLs :: [FilePath]
- pkgRoot :: Maybe FilePath
- installedComponentId :: InstalledPackageInfo -> ComponentId
- installedPackageId :: InstalledPackageInfo -> UnitId
- data OriginalModule = OriginalModule {}
- data ExposedModule = ExposedModule {}
- data ParseResult a
- = ParseFailed PError
- | ParseOk [PWarning] a
- data PError
- data PWarning
- emptyInstalledPackageInfo :: InstalledPackageInfo
- parseInstalledPackageInfo :: String -> ParseResult InstalledPackageInfo
- showInstalledPackageInfo :: InstalledPackageInfo -> String
- showInstalledPackageInfoField :: String -> Maybe (InstalledPackageInfo -> String)
- showSimpleInstalledPackageInfoField :: String -> Maybe (InstalledPackageInfo -> String)
- fieldsInstalledPackageInfo :: [FieldDescr InstalledPackageInfo]
Documentation
data InstalledPackageInfo Source
InstalledPackageInfo | |
|
installedPackageId :: InstalledPackageInfo -> UnitId Source
Deprecated: Use installedUnitId instead
Backwards compatibility with pre-Cabal 1.23.
data OriginalModule Source
Eq OriginalModule | |
Read OriginalModule | |
Show OriginalModule | |
Generic OriginalModule | |
Binary OriginalModule | |
Text OriginalModule | |
type Rep OriginalModule = D1 (MetaData "OriginalModule" "Distribution.InstalledPackageInfo" "Cabal-1.23.1.0" False) (C1 (MetaCons "OriginalModule" PrefixI True) ((:*:) (S1 (MetaSel (Just Symbol "originalPackageId") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 UnitId)) (S1 (MetaSel (Just Symbol "originalModuleName") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 ModuleName)))) |
data ExposedModule Source
Eq ExposedModule | |
Read ExposedModule | |
Show ExposedModule | |
Generic ExposedModule | |
Binary ExposedModule | |
Text ExposedModule | |
type Rep ExposedModule = D1 (MetaData "ExposedModule" "Distribution.InstalledPackageInfo" "Cabal-1.23.1.0" False) (C1 (MetaCons "ExposedModule" PrefixI True) ((:*:) (S1 (MetaSel (Just Symbol "exposedName") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 ModuleName)) (S1 (MetaSel (Just Symbol "exposedReexport") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Maybe OriginalModule))))) |
data ParseResult a Source