Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- data GenericPackageDescription = GenericPackageDescription {
- packageDescription :: PackageDescription
- genPackageFlags :: [Flag]
- condLibrary :: Maybe (CondTree ConfVar [Dependency] Library)
- condSubLibraries :: [(UnqualComponentName, CondTree ConfVar [Dependency] Library)]
- condForeignLibs :: [(UnqualComponentName, CondTree ConfVar [Dependency] ForeignLib)]
- condExecutables :: [(UnqualComponentName, CondTree ConfVar [Dependency] Executable)]
- condTestSuites :: [(UnqualComponentName, CondTree ConfVar [Dependency] TestSuite)]
- condBenchmarks :: [(UnqualComponentName, CondTree ConfVar [Dependency] Benchmark)]
- data Flag = MkFlag {}
- emptyFlag :: FlagName -> Flag
- data FlagName
- mkFlagName :: String -> FlagName
- unFlagName :: FlagName -> String
- type FlagAssignment = [(FlagName, Bool)]
- showFlagValue :: (FlagName, Bool) -> String
- dispFlagAssignment :: FlagAssignment -> Doc
- parseFlagAssignment :: ReadP r FlagAssignment
- data ConfVar
Documentation
data GenericPackageDescription Source #
Instances
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.
MkFlag | |
|
Instances
Eq Flag Source # | |
Data Flag Source # | |
gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Flag -> c Flag # gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Flag # dataTypeOf :: Flag -> DataType # dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c Flag) # dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Flag) # gmapT :: (forall b. Data b => b -> b) -> Flag -> Flag # gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Flag -> r # gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Flag -> r # gmapQ :: (forall d. Data d => d -> u) -> Flag -> [u] # gmapQi :: Int -> (forall d. Data d => d -> u) -> Flag -> u # gmapM :: Monad m => (forall d. Data d => d -> m d) -> Flag -> m Flag # gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Flag -> m Flag # gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Flag -> m Flag # | |
Show Flag Source # | |
Generic Flag Source # | |
Binary Flag Source # | |
type Rep Flag Source # | |
type Rep Flag = D1 * (MetaData "Flag" "Distribution.Types.GenericPackageDescription" "Cabal-2.0.1.1-99tbaCBn5in8ykZQ2Yxqis" False) (C1 * (MetaCons "MkFlag" PrefixI True) ((:*:) * ((:*:) * (S1 * (MetaSel (Just Symbol "flagName") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 * FlagName)) (S1 * (MetaSel (Just Symbol "flagDescription") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 * String))) ((:*:) * (S1 * (MetaSel (Just Symbol "flagDefault") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 * Bool)) (S1 * (MetaSel (Just Symbol "flagManual") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 * Bool))))) |
A FlagName
is the name of a user-defined configuration flag
Use mkFlagName
and unFlagName
to convert from/to a String
.
This type is opaque since Cabal-2.0
Since: 2.0.0.2
Instances
Eq FlagName Source # | |
Data FlagName Source # | |
gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> FlagName -> c FlagName # gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c FlagName # toConstr :: FlagName -> Constr # dataTypeOf :: FlagName -> DataType # dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c FlagName) # dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c FlagName) # gmapT :: (forall b. Data b => b -> b) -> FlagName -> FlagName # gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> FlagName -> r # gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> FlagName -> r # gmapQ :: (forall d. Data d => d -> u) -> FlagName -> [u] # gmapQi :: Int -> (forall d. Data d => d -> u) -> FlagName -> u # gmapM :: Monad m => (forall d. Data d => d -> m d) -> FlagName -> m FlagName # gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> FlagName -> m FlagName # gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> FlagName -> m FlagName # | |
Ord FlagName Source # | |
Read FlagName Source # | |
Show FlagName Source # | |
IsString FlagName Source # | Since: 2.0.0.2 |
fromString :: String -> FlagName # | |
Generic FlagName Source # | |
Binary FlagName Source # | |
type Rep FlagName Source # | |
mkFlagName :: String -> FlagName Source #
Construct a FlagName
from a String
mkFlagName
is the inverse to unFlagName
Note: No validations are performed to ensure that the resulting
FlagName
is valid
Since: 2.0.0.2
type FlagAssignment = [(FlagName, Bool)] Source #
A FlagAssignment
is a total or partial mapping of FlagName
s 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)]
dispFlagAssignment :: FlagAssignment -> Doc Source #
Pretty-prints a flag assignment.
parseFlagAssignment :: ReadP r FlagAssignment Source #
Parses a flag assignment.
A ConfVar
represents the variable type used.