Cabal-1.24.2.0: A framework for packaging Haskell software

CopyrightIsaac Jones 2003-2005
LicenseBSD3
Maintainer[email protected]
Portabilityportable
Safe HaskellNone
LanguageHaskell98

Distribution.PackageDescription

Contents

Description

This defines the data structure for the .cabal file format. There are several parts to this structure. It has top level info and then Library, Executable, TestSuite, and Benchmark sections each of which have associated BuildInfo data that's used to build the library, exe, test, or benchmark. To further complicate things there is both a PackageDescription and a GenericPackageDescription. This distinction relates to cabal configurations. When we initially read a .cabal file we get a GenericPackageDescription which has all the conditional sections. Before actually building a package we have to decide on each conditional. Once we've done that we get a PackageDescription. It was done this way initially to avoid breaking too much stuff when the feature was introduced. It could probably do with being rationalised at some point to make it simpler.

Synopsis

Package descriptions

data PackageDescription Source #

This data type is the internal representation of the file pkg.cabal. It contains two kinds of information about the package: information which is needed for all packages, such as the package name and version, and information which is needed for the simple build system only, such as the compiler options and library name.

Constructors

PackageDescription 

Fields

Instances

Eq PackageDescription # 
Data PackageDescription # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> PackageDescription -> c PackageDescription Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c PackageDescription Source #

toConstr :: PackageDescription -> Constr Source #

dataTypeOf :: PackageDescription -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c PackageDescription) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c PackageDescription) Source #

gmapT :: (forall b. Data b => b -> b) -> PackageDescription -> PackageDescription Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> PackageDescription -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> PackageDescription -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> PackageDescription -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> PackageDescription -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> PackageDescription -> m PackageDescription Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> PackageDescription -> m PackageDescription Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> PackageDescription -> m PackageDescription Source #

Read PackageDescription # 
Show PackageDescription # 
Generic PackageDescription # 
Binary PackageDescription # 
Package PackageDescription # 
type Rep PackageDescription # 
type Rep PackageDescription = D1 (MetaData "PackageDescription" "Distribution.PackageDescription" "Cabal-1.24.2.0" False) (C1 (MetaCons "PackageDescription" PrefixI True) ((:*:) ((:*:) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "package") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 PackageIdentifier)) ((:*:) (S1 (MetaSel (Just Symbol "license") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 License)) (S1 (MetaSel (Just Symbol "licenseFiles") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [FilePath])))) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "copyright") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 String)) (S1 (MetaSel (Just Symbol "maintainer") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 String))) ((:*:) (S1 (MetaSel (Just Symbol "author") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 String)) (S1 (MetaSel (Just Symbol "stability") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 String))))) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "testedWith") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [(CompilerFlavor, VersionRange)])) ((:*:) (S1 (MetaSel (Just Symbol "homepage") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 String)) (S1 (MetaSel (Just Symbol "pkgUrl") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 String)))) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "bugReports") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 String)) (S1 (MetaSel (Just Symbol "sourceRepos") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [SourceRepo]))) ((:*:) (S1 (MetaSel (Just Symbol "synopsis") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 String)) (S1 (MetaSel (Just Symbol "description") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 String)))))) ((:*:) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "category") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 String)) ((:*:) (S1 (MetaSel (Just Symbol "customFieldsPD") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [(String, String)])) (S1 (MetaSel (Just Symbol "buildDepends") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [Dependency])))) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "specVersionRaw") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Either Version VersionRange))) (S1 (MetaSel (Just Symbol "buildType") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Maybe BuildType)))) ((:*:) (S1 (MetaSel (Just Symbol "setupBuildInfo") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Maybe SetupBuildInfo))) (S1 (MetaSel (Just Symbol "library") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Maybe Library)))))) ((:*:) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "executables") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [Executable])) (S1 (MetaSel (Just Symbol "testSuites") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [TestSuite]))) ((:*:) (S1 (MetaSel (Just Symbol "benchmarks") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [Benchmark])) (S1 (MetaSel (Just Symbol "dataFiles") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [FilePath])))) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "dataDir") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 FilePath)) (S1 (MetaSel (Just Symbol "extraSrcFiles") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [FilePath]))) ((:*:) (S1 (MetaSel (Just Symbol "extraTmpFiles") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [FilePath])) (S1 (MetaSel (Just Symbol "extraDocFiles") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [FilePath]))))))))

specVersion :: PackageDescription -> Version Source #

The version of the Cabal spec that this package should be interpreted against.

Historically we used a version range but we are switching to using a single version. Currently we accept either. This function converts into a single version by ignoring upper bounds in the version range.

descCabalVersion :: PackageDescription -> VersionRange Source #

Deprecated: Use specVersion instead

The range of versions of the Cabal tools that this package is intended to work with.

This function is deprecated and should not be used for new purposes, only to support old packages that rely on the old interpretation.

data BuildType Source #

The type of build system used by this package.

Constructors

Simple

calls Distribution.Simple.defaultMain

Configure

calls Distribution.Simple.defaultMainWithHooks defaultUserHooks, which invokes configure to generate additional build information used by later phases.

Make

calls Distribution.Make.defaultMain

Custom

uses user-supplied Setup.hs or Setup.lhs (default)

UnknownBuildType String

a package that uses an unknown build type cannot actually be built. Doing it this way rather than just giving a parse error means we get better error messages and allows you to inspect the rest of the package description.

Instances

Eq BuildType # 
Data BuildType # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> BuildType -> c BuildType Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c BuildType Source #

toConstr :: BuildType -> Constr Source #

dataTypeOf :: BuildType -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c BuildType) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c BuildType) Source #

gmapT :: (forall b. Data b => b -> b) -> BuildType -> BuildType Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> BuildType -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> BuildType -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> BuildType -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> BuildType -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> BuildType -> m BuildType Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> BuildType -> m BuildType Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> BuildType -> m BuildType Source #

Read BuildType # 
Show BuildType # 
Generic BuildType # 

Associated Types

type Rep BuildType :: * -> * Source #

Binary BuildType # 
Text BuildType # 
type Rep BuildType # 
type Rep BuildType = D1 (MetaData "BuildType" "Distribution.PackageDescription" "Cabal-1.24.2.0" False) ((:+:) ((:+:) (C1 (MetaCons "Simple" PrefixI False) U1) (C1 (MetaCons "Configure" PrefixI False) U1)) ((:+:) (C1 (MetaCons "Make" PrefixI False) U1) ((:+:) (C1 (MetaCons "Custom" PrefixI False) U1) (C1 (MetaCons "UnknownBuildType" PrefixI False) (S1 (MetaSel (Nothing Symbol) NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 String))))))

Renaming

data ModuleRenaming Source #

Renaming applied to the modules provided by a package. The boolean indicates whether or not to also include all of the original names of modules. Thus, ModuleRenaming False [] is "don't expose any modules, and ModuleRenaming True [(Data.Bool, Bool)] is, "expose all modules, but also expose Data.Bool as Bool".

Instances

Eq ModuleRenaming # 
Data ModuleRenaming # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> ModuleRenaming -> c ModuleRenaming Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c ModuleRenaming Source #

toConstr :: ModuleRenaming -> Constr Source #

dataTypeOf :: ModuleRenaming -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c ModuleRenaming) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c ModuleRenaming) Source #

gmapT :: (forall b. Data b => b -> b) -> ModuleRenaming -> ModuleRenaming Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> ModuleRenaming -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> ModuleRenaming -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> ModuleRenaming -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> ModuleRenaming -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> ModuleRenaming -> m ModuleRenaming Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> ModuleRenaming -> m ModuleRenaming Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> ModuleRenaming -> m ModuleRenaming Source #

Ord ModuleRenaming # 
Read ModuleRenaming # 
Show ModuleRenaming # 
Generic ModuleRenaming # 
Semigroup ModuleRenaming # 
Monoid ModuleRenaming # 
Binary ModuleRenaming # 
Text ModuleRenaming # 
type Rep ModuleRenaming # 

Libraries

data Library Source #

Constructors

Library 

Fields

Instances

Eq Library # 

Methods

(==) :: Library -> Library -> Bool #

(/=) :: Library -> Library -> Bool #

Data Library # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Library -> c Library Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Library Source #

toConstr :: Library -> Constr Source #

dataTypeOf :: Library -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c Library) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Library) Source #

gmapT :: (forall b. Data b => b -> b) -> Library -> Library Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Library -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Library -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> Library -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> Library -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> Library -> m Library Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Library -> m Library Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Library -> m Library Source #

Read Library # 
Show Library # 
Generic Library # 

Associated Types

type Rep Library :: * -> * Source #

Semigroup Library # 
Monoid Library # 
Binary Library # 
type Rep Library # 

data ModuleReexport Source #

Instances

Eq ModuleReexport # 
Data ModuleReexport # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> ModuleReexport -> c ModuleReexport Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c ModuleReexport Source #

toConstr :: ModuleReexport -> Constr Source #

dataTypeOf :: ModuleReexport -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c ModuleReexport) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c ModuleReexport) Source #

gmapT :: (forall b. Data b => b -> b) -> ModuleReexport -> ModuleReexport Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> ModuleReexport -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> ModuleReexport -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> ModuleReexport -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> ModuleReexport -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> ModuleReexport -> m ModuleReexport Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> ModuleReexport -> m ModuleReexport Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> ModuleReexport -> m ModuleReexport Source #

Read ModuleReexport # 
Show ModuleReexport # 
Generic ModuleReexport # 
Binary ModuleReexport # 
Text ModuleReexport # 
type Rep ModuleReexport # 
type Rep ModuleReexport = D1 (MetaData "ModuleReexport" "Distribution.PackageDescription" "Cabal-1.24.2.0" False) (C1 (MetaCons "ModuleReexport" PrefixI True) ((:*:) (S1 (MetaSel (Just Symbol "moduleReexportOriginalPackage") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Maybe PackageName))) ((:*:) (S1 (MetaSel (Just Symbol "moduleReexportOriginalName") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 ModuleName)) (S1 (MetaSel (Just Symbol "moduleReexportName") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 ModuleName)))))

withLib :: PackageDescription -> (Library -> IO ()) -> IO () Source #

If the package description has a library section, call the given function with the library build info as argument.

hasLibs :: PackageDescription -> Bool Source #

does this package have any libraries?

libModules :: Library -> [ModuleName] Source #

Get all the module names from the library (exposed and internal modules) which need to be compiled. (This does not include reexports, which do not need to be compiled.)

Executables

data Executable Source #

Instances

Eq Executable # 
Data Executable # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Executable -> c Executable Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Executable Source #

toConstr :: Executable -> Constr Source #

dataTypeOf :: Executable -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c Executable) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Executable) Source #

gmapT :: (forall b. Data b => b -> b) -> Executable -> Executable Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Executable -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Executable -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> Executable -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> Executable -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> Executable -> m Executable Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Executable -> m Executable Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Executable -> m Executable Source #

Read Executable # 
Show Executable # 
Generic Executable # 

Associated Types

type Rep Executable :: * -> * Source #

Semigroup Executable # 
Monoid Executable # 
Binary Executable # 
type Rep Executable # 

withExe :: PackageDescription -> (Executable -> IO ()) -> IO () Source #

Perform the action on each buildable Executable in the package description.

hasExes :: PackageDescription -> Bool Source #

does this package have any executables?

exeModules :: Executable -> [ModuleName] Source #

Get all the module names from an exe

Tests

data TestSuite Source #

A "test-suite" stanza in a cabal file.

Instances

Eq TestSuite # 
Data TestSuite # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> TestSuite -> c TestSuite Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c TestSuite Source #

toConstr :: TestSuite -> Constr Source #

dataTypeOf :: TestSuite -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c TestSuite) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c TestSuite) Source #

gmapT :: (forall b. Data b => b -> b) -> TestSuite -> TestSuite Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> TestSuite -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> TestSuite -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> TestSuite -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> TestSuite -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> TestSuite -> m TestSuite Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> TestSuite -> m TestSuite Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> TestSuite -> m TestSuite Source #

Read TestSuite # 
Show TestSuite # 
Generic TestSuite # 

Associated Types

type Rep TestSuite :: * -> * Source #

Semigroup TestSuite # 
Monoid TestSuite # 
Binary TestSuite # 
type Rep TestSuite # 

data TestSuiteInterface Source #

The test suite interfaces that are currently defined. Each test suite must specify which interface it supports.

More interfaces may be defined in future, either new revisions or totally new interfaces.

Constructors

TestSuiteExeV10 Version FilePath

Test interface "exitcode-stdio-1.0". The test-suite takes the form of an executable. It returns a zero exit code for success, non-zero for failure. The stdout and stderr channels may be logged. It takes no command line parameters and nothing on stdin.

TestSuiteLibV09 Version ModuleName

Test interface "detailed-0.9". The test-suite takes the form of a library containing a designated module that exports "tests :: [Test]".

TestSuiteUnsupported TestType

A test suite that does not conform to one of the above interfaces for the given reason (e.g. unknown test type).

Instances

Eq TestSuiteInterface # 
Data TestSuiteInterface # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> TestSuiteInterface -> c TestSuiteInterface Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c TestSuiteInterface Source #

toConstr :: TestSuiteInterface -> Constr Source #

dataTypeOf :: TestSuiteInterface -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c TestSuiteInterface) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c TestSuiteInterface) Source #

gmapT :: (forall b. Data b => b -> b) -> TestSuiteInterface -> TestSuiteInterface Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> TestSuiteInterface -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> TestSuiteInterface -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> TestSuiteInterface -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> TestSuiteInterface -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> TestSuiteInterface -> m TestSuiteInterface Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> TestSuiteInterface -> m TestSuiteInterface Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> TestSuiteInterface -> m TestSuiteInterface Source #

Read TestSuiteInterface # 
Show TestSuiteInterface # 
Generic TestSuiteInterface # 
Semigroup TestSuiteInterface # 
Monoid TestSuiteInterface # 
Binary TestSuiteInterface # 
type Rep TestSuiteInterface # 

data TestType Source #

The "test-type" field in the test suite stanza.

Constructors

TestTypeExe Version

"type: exitcode-stdio-x.y"

TestTypeLib Version

"type: detailed-x.y"

TestTypeUnknown String Version

Some unknown test type e.g. "type: foo"

Instances

Eq TestType # 
Data TestType # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> TestType -> c TestType Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c TestType Source #

toConstr :: TestType -> Constr Source #

dataTypeOf :: TestType -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c TestType) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c TestType) Source #

gmapT :: (forall b. Data b => b -> b) -> TestType -> TestType Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> TestType -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> TestType -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> TestType -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> TestType -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> TestType -> m TestType Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> TestType -> m TestType Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> TestType -> m TestType Source #

Read TestType # 
Show TestType # 
Generic TestType # 

Associated Types

type Rep TestType :: * -> * Source #

Binary TestType # 
Text TestType # 
type Rep TestType # 

hasTests :: PackageDescription -> Bool Source #

Does this package have any test suites?

withTest :: PackageDescription -> (TestSuite -> IO ()) -> IO () Source #

Perform an action on each buildable TestSuite in a package.

testModules :: TestSuite -> [ModuleName] Source #

Get all the module names from a test suite.

enabledTests :: PackageDescription -> [TestSuite] Source #

Get all the enabled test suites from a package.

Benchmarks

data Benchmark Source #

A "benchmark" stanza in a cabal file.

Instances

Eq Benchmark # 
Data Benchmark # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Benchmark -> c Benchmark Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Benchmark Source #

toConstr :: Benchmark -> Constr Source #

dataTypeOf :: Benchmark -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c Benchmark) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Benchmark) Source #

gmapT :: (forall b. Data b => b -> b) -> Benchmark -> Benchmark Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Benchmark -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Benchmark -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> Benchmark -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> Benchmark -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> Benchmark -> m Benchmark Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Benchmark -> m Benchmark Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Benchmark -> m Benchmark Source #

Read Benchmark # 
Show Benchmark # 
Generic Benchmark # 

Associated Types

type Rep Benchmark :: * -> * Source #

Semigroup Benchmark # 
Monoid Benchmark # 
Binary Benchmark # 
type Rep Benchmark # 

data BenchmarkInterface Source #

The benchmark interfaces that are currently defined. Each benchmark must specify which interface it supports.

More interfaces may be defined in future, either new revisions or totally new interfaces.

Constructors

BenchmarkExeV10 Version FilePath

Benchmark interface "exitcode-stdio-1.0". The benchmark takes the form of an executable. It returns a zero exit code for success, non-zero for failure. The stdout and stderr channels may be logged. It takes no command line parameters and nothing on stdin.

BenchmarkUnsupported BenchmarkType

A benchmark that does not conform to one of the above interfaces for the given reason (e.g. unknown benchmark type).

Instances

Eq BenchmarkInterface # 
Data BenchmarkInterface # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> BenchmarkInterface -> c BenchmarkInterface Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c BenchmarkInterface Source #

toConstr :: BenchmarkInterface -> Constr Source #

dataTypeOf :: BenchmarkInterface -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c BenchmarkInterface) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c BenchmarkInterface) Source #

gmapT :: (forall b. Data b => b -> b) -> BenchmarkInterface -> BenchmarkInterface Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> BenchmarkInterface -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> BenchmarkInterface -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> BenchmarkInterface -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> BenchmarkInterface -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> BenchmarkInterface -> m BenchmarkInterface Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> BenchmarkInterface -> m BenchmarkInterface Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> BenchmarkInterface -> m BenchmarkInterface Source #

Read BenchmarkInterface # 
Show BenchmarkInterface # 
Generic BenchmarkInterface # 
Semigroup BenchmarkInterface # 
Monoid BenchmarkInterface # 
Binary BenchmarkInterface # 
type Rep BenchmarkInterface # 

data BenchmarkType Source #

The "benchmark-type" field in the benchmark stanza.

Constructors

BenchmarkTypeExe Version

"type: exitcode-stdio-x.y"

BenchmarkTypeUnknown String Version

Some unknown benchmark type e.g. "type: foo"

Instances

Eq BenchmarkType # 
Data BenchmarkType # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> BenchmarkType -> c BenchmarkType Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c BenchmarkType Source #

toConstr :: BenchmarkType -> Constr Source #

dataTypeOf :: BenchmarkType -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c BenchmarkType) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c BenchmarkType) Source #

gmapT :: (forall b. Data b => b -> b) -> BenchmarkType -> BenchmarkType Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> BenchmarkType -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> BenchmarkType -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> BenchmarkType -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> BenchmarkType -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> BenchmarkType -> m BenchmarkType Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> BenchmarkType -> m BenchmarkType Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> BenchmarkType -> m BenchmarkType Source #

Read BenchmarkType # 
Show BenchmarkType # 
Generic BenchmarkType # 
Binary BenchmarkType # 
Text BenchmarkType # 
type Rep BenchmarkType # 

hasBenchmarks :: PackageDescription -> Bool Source #

Does this package have any benchmarks?

withBenchmark :: PackageDescription -> (Benchmark -> IO ()) -> IO () Source #

Perform an action on each buildable Benchmark in a package.

benchmarkModules :: Benchmark -> [ModuleName] Source #

Get all the module names from a benchmark.

enabledBenchmarks :: PackageDescription -> [Benchmark] Source #

Get all the enabled benchmarks from a package.

Build information

data BuildInfo Source #

Constructors

BuildInfo 

Fields

Instances

Eq BuildInfo # 
Data BuildInfo # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> BuildInfo -> c BuildInfo Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c BuildInfo Source #

toConstr :: BuildInfo -> Constr Source #

dataTypeOf :: BuildInfo -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c BuildInfo) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c BuildInfo) Source #

gmapT :: (forall b. Data b => b -> b) -> BuildInfo -> BuildInfo Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> BuildInfo -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> BuildInfo -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> BuildInfo -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> BuildInfo -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> BuildInfo -> m BuildInfo Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> BuildInfo -> m BuildInfo Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> BuildInfo -> m BuildInfo Source #

Read BuildInfo # 
Show BuildInfo # 
Generic BuildInfo # 

Associated Types

type Rep BuildInfo :: * -> * Source #

Semigroup BuildInfo # 
Monoid BuildInfo # 
Binary BuildInfo # 
type Rep BuildInfo # 
type Rep BuildInfo = D1 (MetaData "BuildInfo" "Distribution.PackageDescription" "Cabal-1.24.2.0" False) (C1 (MetaCons "BuildInfo" PrefixI True) ((:*:) ((:*:) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "buildable") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Bool)) ((:*:) (S1 (MetaSel (Just Symbol "buildTools") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [Dependency])) (S1 (MetaSel (Just Symbol "cppOptions") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [String])))) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "ccOptions") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [String])) (S1 (MetaSel (Just Symbol "ldOptions") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [String]))) ((:*:) (S1 (MetaSel (Just Symbol "pkgconfigDepends") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [Dependency])) (S1 (MetaSel (Just Symbol "frameworks") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [String]))))) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "extraFrameworkDirs") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [String])) ((:*:) (S1 (MetaSel (Just Symbol "cSources") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [FilePath])) (S1 (MetaSel (Just Symbol "jsSources") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [FilePath])))) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "hsSourceDirs") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [FilePath])) (S1 (MetaSel (Just Symbol "otherModules") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [ModuleName]))) ((:*:) (S1 (MetaSel (Just Symbol "defaultLanguage") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Maybe Language))) (S1 (MetaSel (Just Symbol "otherLanguages") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [Language])))))) ((:*:) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "defaultExtensions") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [Extension])) ((:*:) (S1 (MetaSel (Just Symbol "otherExtensions") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [Extension])) (S1 (MetaSel (Just Symbol "oldExtensions") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [Extension])))) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "extraLibs") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [String])) (S1 (MetaSel (Just Symbol "extraGHCiLibs") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [String]))) ((:*:) (S1 (MetaSel (Just Symbol "extraLibDirs") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [String])) (S1 (MetaSel (Just Symbol "includeDirs") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [FilePath]))))) ((:*:) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "includes") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [FilePath])) (S1 (MetaSel (Just Symbol "installIncludes") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [FilePath]))) ((:*:) (S1 (MetaSel (Just Symbol "options") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [(CompilerFlavor, [String])])) (S1 (MetaSel (Just Symbol "profOptions") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [(CompilerFlavor, [String])])))) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "sharedOptions") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [(CompilerFlavor, [String])])) (S1 (MetaSel (Just Symbol "customFieldsBI") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [(String, String)]))) ((:*:) (S1 (MetaSel (Just Symbol "targetBuildDepends") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [Dependency])) (S1 (MetaSel (Just Symbol "targetBuildRenaming") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Map PackageName ModuleRenaming)))))))))

allBuildInfo :: PackageDescription -> [BuildInfo] Source #

The BuildInfo for the library (if there is one and it's buildable), and all buildable executables, test suites and benchmarks. Useful for gathering dependencies.

allLanguages :: BuildInfo -> [Language] Source #

The Languages used by this component

allExtensions :: BuildInfo -> [Extension] Source #

The Extensions that are used somewhere by this component

usedExtensions :: BuildInfo -> [Extension] Source #

The Extensions that are used by all modules in this component

hcOptions :: CompilerFlavor -> BuildInfo -> [String] Source #

Select options for a particular Haskell compiler.

Supplementary build information

package configuration

data GenericPackageDescription Source #

Instances

Eq GenericPackageDescription # 
Data GenericPackageDescription # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> GenericPackageDescription -> c GenericPackageDescription Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c GenericPackageDescription Source #

toConstr :: GenericPackageDescription -> Constr Source #

dataTypeOf :: GenericPackageDescription -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c GenericPackageDescription) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c GenericPackageDescription) Source #

gmapT :: (forall b. Data b => b -> b) -> GenericPackageDescription -> GenericPackageDescription Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> GenericPackageDescription -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> GenericPackageDescription -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> GenericPackageDescription -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> GenericPackageDescription -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> GenericPackageDescription -> m GenericPackageDescription Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> GenericPackageDescription -> m GenericPackageDescription Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> GenericPackageDescription -> m GenericPackageDescription Source #

Show GenericPackageDescription # 
Generic GenericPackageDescription # 
Binary GenericPackageDescription # 
Package GenericPackageDescription # 
type Rep GenericPackageDescription # 

data Flag Source #

A flag can represent a feature to be included, or a way of linking a target against its dependencies, or in fact whatever you can think of.

Instances

Eq Flag # 

Methods

(==) :: Flag -> Flag -> Bool #

(/=) :: Flag -> Flag -> Bool #

Data Flag # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Flag -> c Flag Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Flag Source #

toConstr :: Flag -> Constr Source #

dataTypeOf :: Flag -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c Flag) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Flag) Source #

gmapT :: (forall b. Data b => b -> b) -> Flag -> Flag Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Flag -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Flag -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> Flag -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> Flag -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> Flag -> m Flag Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Flag -> m Flag Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Flag -> m Flag Source #

Show Flag # 
Generic Flag # 

Associated Types

type Rep Flag :: * -> * Source #

Methods

from :: Flag -> Rep Flag x Source #

to :: Rep Flag x -> Flag Source #

Binary Flag # 
type Rep Flag # 

newtype FlagName Source #

A FlagName is the name of a user-defined configuration flag

Constructors

FlagName String 

Instances

Eq FlagName # 
Data FlagName # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> FlagName -> c FlagName Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c FlagName Source #

toConstr :: FlagName -> Constr Source #

dataTypeOf :: FlagName -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c FlagName) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c FlagName) Source #

gmapT :: (forall b. Data b => b -> b) -> FlagName -> FlagName Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> FlagName -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> FlagName -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> FlagName -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> FlagName -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> FlagName -> m FlagName Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> FlagName -> m FlagName Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> FlagName -> m FlagName Source #

Ord FlagName # 
Read FlagName # 
Show FlagName # 
Generic FlagName # 

Associated Types

type Rep FlagName :: * -> * Source #

Binary FlagName # 
type Rep FlagName # 
type Rep FlagName = D1 (MetaData "FlagName" "Distribution.PackageDescription" "Cabal-1.24.2.0" True) (C1 (MetaCons "FlagName" PrefixI False) (S1 (MetaSel (Nothing Symbol) NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 String)))

type FlagAssignment = [(FlagName, Bool)] Source #

A FlagAssignment is a total or partial mapping of FlagNames to Bool flag values. It represents the flags chosen by the user or discovered during configuration. For example --flags=foo --flags=-bar becomes [("foo", True), ("bar", False)]

data CondTree v c a Source #

Constructors

CondNode 

Instances

(Eq v, Eq c, Eq a) => Eq (CondTree v c a) # 

Methods

(==) :: CondTree v c a -> CondTree v c a -> Bool #

(/=) :: CondTree v c a -> CondTree v c a -> Bool #

(Data a, Data c, Data v) => Data (CondTree v c a) # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> CondTree v c a -> c (CondTree v c a) Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c (CondTree v c a) Source #

toConstr :: CondTree v c a -> Constr Source #

dataTypeOf :: CondTree v c a -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c (CondTree v c a)) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c (CondTree v c a)) Source #

gmapT :: (forall b. Data b => b -> b) -> CondTree v c a -> CondTree v c a Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> CondTree v c a -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> CondTree v c a -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> CondTree v c a -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> CondTree v c a -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> CondTree v c a -> m (CondTree v c a) Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> CondTree v c a -> m (CondTree v c a) Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> CondTree v c a -> m (CondTree v c a) Source #

(Show v, Show c, Show a) => Show (CondTree v c a) # 

Methods

showsPrec :: Int -> CondTree v c a -> ShowS Source #

show :: CondTree v c a -> String Source #

showList :: [CondTree v c a] -> ShowS Source #

Generic (CondTree v c a) # 

Associated Types

type Rep (CondTree v c a) :: * -> * Source #

Methods

from :: CondTree v c a -> Rep (CondTree v c a) x Source #

to :: Rep (CondTree v c a) x -> CondTree v c a Source #

(Binary v, Binary c, Binary a) => Binary (CondTree v c a) # 

Methods

put :: CondTree v c a -> Put Source #

get :: Get (CondTree v c a) Source #

putList :: [CondTree v c a] -> Put Source #

type Rep (CondTree v c a) # 
type Rep (CondTree v c a) = D1 (MetaData "CondTree" "Distribution.PackageDescription" "Cabal-1.24.2.0" False) (C1 (MetaCons "CondNode" PrefixI True) ((:*:) (S1 (MetaSel (Just Symbol "condTreeData") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 a)) ((:*:) (S1 (MetaSel (Just Symbol "condTreeConstraints") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 c)) (S1 (MetaSel (Just Symbol "condTreeComponents") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [(Condition v, CondTree v c a, Maybe (CondTree v c a))])))))

data ConfVar Source #

A ConfVar represents the variable type used.

Instances

Eq ConfVar # 

Methods

(==) :: ConfVar -> ConfVar -> Bool #

(/=) :: ConfVar -> ConfVar -> Bool #

Data ConfVar # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> ConfVar -> c ConfVar Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c ConfVar Source #

toConstr :: ConfVar -> Constr Source #

dataTypeOf :: ConfVar -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c ConfVar) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c ConfVar) Source #

gmapT :: (forall b. Data b => b -> b) -> ConfVar -> ConfVar Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> ConfVar -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> ConfVar -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> ConfVar -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> ConfVar -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> ConfVar -> m ConfVar Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> ConfVar -> m ConfVar Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> ConfVar -> m ConfVar Source #

Show ConfVar # 
Generic ConfVar # 

Associated Types

type Rep ConfVar :: * -> * Source #

Binary ConfVar # 
type Rep ConfVar # 

data Condition c Source #

A boolean expression parameterized over the variable type used.

Constructors

Var c 
Lit Bool 
CNot (Condition c) 
COr (Condition c) (Condition c) 
CAnd (Condition c) (Condition c) 

Instances

Monad Condition # 
Functor Condition # 

Methods

fmap :: (a -> b) -> Condition a -> Condition b Source #

(<$) :: a -> Condition b -> Condition a Source #

Applicative Condition # 
Foldable Condition # 

Methods

fold :: Monoid m => Condition m -> m Source #

foldMap :: Monoid m => (a -> m) -> Condition a -> m Source #

foldr :: (a -> b -> b) -> b -> Condition a -> b Source #

foldr' :: (a -> b -> b) -> b -> Condition a -> b Source #

foldl :: (b -> a -> b) -> b -> Condition a -> b Source #

foldl' :: (b -> a -> b) -> b -> Condition a -> b Source #

foldr1 :: (a -> a -> a) -> Condition a -> a Source #

foldl1 :: (a -> a -> a) -> Condition a -> a Source #

toList :: Condition a -> [a] Source #

null :: Condition a -> Bool Source #

length :: Condition a -> Int Source #

elem :: Eq a => a -> Condition a -> Bool Source #

maximum :: Ord a => Condition a -> a Source #

minimum :: Ord a => Condition a -> a Source #

sum :: Num a => Condition a -> a Source #

product :: Num a => Condition a -> a Source #

Traversable Condition # 

Methods

traverse :: Applicative f => (a -> f b) -> Condition a -> f (Condition b) Source #

sequenceA :: Applicative f => Condition (f a) -> f (Condition a) Source #

mapM :: Monad m => (a -> m b) -> Condition a -> m (Condition b) Source #

sequence :: Monad m => Condition (m a) -> m (Condition a) Source #

Alternative Condition # 
MonadPlus Condition # 
Eq c => Eq (Condition c) # 

Methods

(==) :: Condition c -> Condition c -> Bool #

(/=) :: Condition c -> Condition c -> Bool #

Data c => Data (Condition c) # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Condition c -> c (Condition c) Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c (Condition c) Source #

toConstr :: Condition c -> Constr Source #

dataTypeOf :: Condition c -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c (Condition c)) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c (Condition c)) Source #

gmapT :: (forall b. Data b => b -> b) -> Condition c -> Condition c Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Condition c -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Condition c -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> Condition c -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> Condition c -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> Condition c -> m (Condition c) Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Condition c -> m (Condition c) Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Condition c -> m (Condition c) Source #

Show c => Show (Condition c) # 
Generic (Condition c) # 

Associated Types

type Rep (Condition c) :: * -> * Source #

Methods

from :: Condition c -> Rep (Condition c) x Source #

to :: Rep (Condition c) x -> Condition c Source #

Semigroup (Condition a) # 
Monoid (Condition a) # 
Binary c => Binary (Condition c) # 
type Rep (Condition c) # 

cNot :: Condition a -> Condition a Source #

Boolean negation of a Condition value.

cAnd :: Condition a -> Condition a -> Condition a Source #

Boolean AND of two Condtion values.

cOr :: Eq v => Condition v -> Condition v -> Condition v Source #

Boolean OR of two Condition values.

Source repositories

data SourceRepo Source #

Information about the source revision control system for a package.

When specifying a repo it is useful to know the meaning or intention of the information as doing so enables automation. There are two obvious common purposes: one is to find the repo for the latest development version, the other is to find the repo for this specific release. The ReopKind specifies which one we mean (or another custom one).

A package can specify one or the other kind or both. Most will specify just a head repo but some may want to specify a repo to reconstruct the sources for this package release.

The required information is the RepoType which tells us if it's using Darcs, Git for example. The repoLocation and other details are interpreted according to the repo type.

Constructors

SourceRepo 

Fields

  • repoKind :: RepoKind

    The kind of repo. This field is required.

  • repoType :: Maybe RepoType

    The type of the source repository system for this repo, eg Darcs or Git. This field is required.

  • repoLocation :: Maybe String

    The location of the repository. For most RepoTypes this is a URL. This field is required.

  • repoModule :: Maybe String

    CVS can put multiple "modules" on one server and requires a module name in addition to the location to identify a particular repo. Logically this is part of the location but unfortunately has to be specified separately. This field is required for the CVS RepoType and should not be given otherwise.

  • repoBranch :: Maybe String

    The name or identifier of the branch, if any. Many source control systems have the notion of multiple branches in a repo that exist in the same location. For example Git and CVS use this while systems like Darcs use different locations for different branches. This field is optional but should be used if necessary to identify the sources, especially for the RepoThis repo kind.

  • repoTag :: Maybe String

    The tag identify a particular state of the repository. This should be given for the RepoThis repo kind and not for RepoHead kind.

  • repoSubdir :: Maybe FilePath

    Some repositories contain multiple projects in different subdirectories This field specifies the subdirectory where this packages sources can be found, eg the subdirectory containing the .cabal file. It is interpreted relative to the root of the repository. This field is optional. If not given the default is "." ie no subdirectory.

Instances

Eq SourceRepo # 
Data SourceRepo # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> SourceRepo -> c SourceRepo Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c SourceRepo Source #

toConstr :: SourceRepo -> Constr Source #

dataTypeOf :: SourceRepo -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c SourceRepo) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c SourceRepo) Source #

gmapT :: (forall b. Data b => b -> b) -> SourceRepo -> SourceRepo Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> SourceRepo -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> SourceRepo -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> SourceRepo -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> SourceRepo -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> SourceRepo -> m SourceRepo Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> SourceRepo -> m SourceRepo Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> SourceRepo -> m SourceRepo Source #

Read SourceRepo # 
Show SourceRepo # 
Generic SourceRepo # 

Associated Types

type Rep SourceRepo :: * -> * Source #

Binary SourceRepo # 
type Rep SourceRepo # 

data RepoKind Source #

What this repo info is for, what it represents.

Constructors

RepoHead

The repository for the "head" or development version of the project. This repo is where we should track the latest development activity or the usual repo people should get to contribute patches.

RepoThis

The repository containing the sources for this exact package version or release. For this kind of repo a tag should be given to give enough information to re-create the exact sources.

RepoKindUnknown String 

Instances

Eq RepoKind # 
Data RepoKind # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> RepoKind -> c RepoKind Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c RepoKind Source #

toConstr :: RepoKind -> Constr Source #

dataTypeOf :: RepoKind -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c RepoKind) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c RepoKind) Source #

gmapT :: (forall b. Data b => b -> b) -> RepoKind -> RepoKind Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> RepoKind -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> RepoKind -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> RepoKind -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> RepoKind -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> RepoKind -> m RepoKind Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> RepoKind -> m RepoKind Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> RepoKind -> m RepoKind Source #

Ord RepoKind # 
Read RepoKind # 
Show RepoKind # 
Generic RepoKind # 

Associated Types

type Rep RepoKind :: * -> * Source #

Binary RepoKind # 
Text RepoKind # 
type Rep RepoKind # 
type Rep RepoKind = D1 (MetaData "RepoKind" "Distribution.PackageDescription" "Cabal-1.24.2.0" False) ((:+:) (C1 (MetaCons "RepoHead" PrefixI False) U1) ((:+:) (C1 (MetaCons "RepoThis" PrefixI False) U1) (C1 (MetaCons "RepoKindUnknown" PrefixI False) (S1 (MetaSel (Nothing Symbol) NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 String)))))

data RepoType Source #

An enumeration of common source control systems. The fields used in the SourceRepo depend on the type of repo. The tools and methods used to obtain and track the repo depend on the repo type.

Instances

Eq RepoType # 
Data RepoType # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> RepoType -> c RepoType Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c RepoType Source #

toConstr :: RepoType -> Constr Source #

dataTypeOf :: RepoType -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c RepoType) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c RepoType) Source #

gmapT :: (forall b. Data b => b -> b) -> RepoType -> RepoType Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> RepoType -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> RepoType -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> RepoType -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> RepoType -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> RepoType -> m RepoType Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> RepoType -> m RepoType Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> RepoType -> m RepoType Source #

Ord RepoType # 
Read RepoType # 
Show RepoType # 
Generic RepoType # 

Associated Types

type Rep RepoType :: * -> * Source #

Binary RepoType # 
Text RepoType # 
type Rep RepoType # 
type Rep RepoType = D1 (MetaData "RepoType" "Distribution.PackageDescription" "Cabal-1.24.2.0" False) ((:+:) ((:+:) ((:+:) (C1 (MetaCons "Darcs" PrefixI False) U1) (C1 (MetaCons "Git" PrefixI False) U1)) ((:+:) (C1 (MetaCons "SVN" PrefixI False) U1) (C1 (MetaCons "CVS" PrefixI False) U1))) ((:+:) ((:+:) (C1 (MetaCons "Mercurial" PrefixI False) U1) (C1 (MetaCons "GnuArch" PrefixI False) U1)) ((:+:) (C1 (MetaCons "Bazaar" PrefixI False) U1) ((:+:) (C1 (MetaCons "Monotone" PrefixI False) U1) (C1 (MetaCons "OtherRepoType" PrefixI False) (S1 (MetaSel (Nothing Symbol) NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 String)))))))

Custom setup build information

data SetupBuildInfo Source #

Constructors

SetupBuildInfo 

Fields

  • setupDepends :: [Dependency]
     
  • defaultSetupDepends :: Bool

    Is this a default 'custom-setup' section added by the cabal-install code (as opposed to user-provided)? This field is only used internally, and doesn't correspond to anything in the .cabal file. See #3199.

Instances

Eq SetupBuildInfo # 
Data SetupBuildInfo # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> SetupBuildInfo -> c SetupBuildInfo Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c SetupBuildInfo Source #

toConstr :: SetupBuildInfo -> Constr Source #

dataTypeOf :: SetupBuildInfo -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c SetupBuildInfo) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c SetupBuildInfo) Source #

gmapT :: (forall b. Data b => b -> b) -> SetupBuildInfo -> SetupBuildInfo Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> SetupBuildInfo -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> SetupBuildInfo -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> SetupBuildInfo -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> SetupBuildInfo -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> SetupBuildInfo -> m SetupBuildInfo Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> SetupBuildInfo -> m SetupBuildInfo Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> SetupBuildInfo -> m SetupBuildInfo Source #

Read SetupBuildInfo # 
Show SetupBuildInfo # 
Generic SetupBuildInfo # 
Semigroup SetupBuildInfo # 
Monoid SetupBuildInfo # 
Binary SetupBuildInfo # 
type Rep SetupBuildInfo # 
type Rep SetupBuildInfo = D1 (MetaData "SetupBuildInfo" "Distribution.PackageDescription" "Cabal-1.24.2.0" False) (C1 (MetaCons "SetupBuildInfo" PrefixI True) ((:*:) (S1 (MetaSel (Just Symbol "setupDepends") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [Dependency])) (S1 (MetaSel (Just Symbol "defaultSetupDepends") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Bool))))