Cabal-1.8.0.6: A framework for packaging Haskell softwareSource codeContentsIndex
Distribution.Simple.Register
Portabilityportable
Maintainercabal-devel@haskell.org
Description

This module deals with registering and unregistering packages. There are a couple ways it can do this, one is to do it directly. Another is to generate a script that can be run later to do it. The idea here being that the user is shielded from the details of what command to use for package registration for a particular compiler. In practice this aspect was not especially popular so we also provide a way to simply generate the package registration file which then must be manually passed to ghc-pkg. It is possible to generate registration information for where the package is to be installed, or alternatively to register the package inplace in the build tree. The latter is occasionally handy, and will become more important when we try to build multi-package systems.

This module does not delegate anything to the per-compiler modules but just mixes it all in in this module, which is rather unsatisfactory. The script generation and the unregister feature are not well used or tested.

Synopsis
register :: PackageDescription -> LocalBuildInfo -> RegisterFlags -> IO ()
unregister :: PackageDescription -> LocalBuildInfo -> RegisterFlags -> IO ()
registerPackage :: Verbosity -> InstalledPackageInfo -> PackageDescription -> LocalBuildInfo -> Bool -> PackageDB -> IO ()
generateRegistrationInfo :: Verbosity -> PackageDescription -> Library -> LocalBuildInfo -> ComponentLocalBuildInfo -> Bool -> FilePath -> IO InstalledPackageInfo
inplaceInstalledPackageInfo :: FilePath -> FilePath -> PackageDescription -> Library -> LocalBuildInfo -> ComponentLocalBuildInfo -> InstalledPackageInfo
absoluteInstalledPackageInfo :: PackageDescription -> Library -> LocalBuildInfo -> ComponentLocalBuildInfo -> InstalledPackageInfo
generalInstalledPackageInfo :: ([FilePath] -> [FilePath]) -> PackageDescription -> Library -> ComponentLocalBuildInfo -> InstallDirs FilePath -> InstalledPackageInfo
Documentation
registerSource
:: PackageDescription
-> LocalBuildInfo
-> RegisterFlagsInstall in the user's database?; verbose
-> IO ()
unregister :: PackageDescription -> LocalBuildInfo -> RegisterFlags -> IO ()Source
registerPackage :: Verbosity -> InstalledPackageInfo -> PackageDescription -> LocalBuildInfo -> Bool -> PackageDB -> IO ()Source
generateRegistrationInfo :: Verbosity -> PackageDescription -> Library -> LocalBuildInfo -> ComponentLocalBuildInfo -> Bool -> FilePath -> IO InstalledPackageInfoSource
inplaceInstalledPackageInfoSource
:: FilePathtop of the build tree
-> FilePathlocation of the dist tree
-> PackageDescription
-> Library
-> LocalBuildInfo
-> ComponentLocalBuildInfo
-> InstalledPackageInfo

Construct InstalledPackageInfo for a library that is inplace in the build tree.

This function knows about the layout of inplace packages.

absoluteInstalledPackageInfo :: PackageDescription -> Library -> LocalBuildInfo -> ComponentLocalBuildInfo -> InstalledPackageInfoSource

Construct InstalledPackageInfo for the final install location of a library package.

This function knows about the layout of installed packages.

generalInstalledPackageInfoSource
:: [FilePath] -> [FilePath]Translate relative include dir paths to absolute paths.
-> PackageDescription
-> Library
-> ComponentLocalBuildInfo
-> InstallDirs FilePath
-> InstalledPackageInfo
Construct InstalledPackageInfo for a library in a package, given a set of installation directories.
Produced by Haddock version 2.6.1