@@ -88,12 +88,13 @@ data BuildConstraints = BuildConstraints
8888 }
8989
9090data PackageConstraints = PackageConstraints
91− { pcVersionRange :: VersionRange
92− , pcMaintainer :: Maybe Maintainer
93− , pcTests :: TestState
94− , pcHaddocks :: TestState
95− , pcBuildBenchmarks :: Bool
96− , pcFlagOverrides :: Map FlagName Bool
91+ { pcVersionRange :: VersionRange
92+ , pcMaintainer :: Maybe Maintainer
93+ , pcTests :: TestState
94+ , pcHaddocks :: TestState
95+ , pcBuildBenchmarks :: Bool
96+ , pcFlagOverrides :: Map FlagName Bool
97+ , pcEnableLibProfile :: Bool
9798 }
9899 deriving (Show, Eq)
99100instance ToJSON PackageConstraints where
@@ -115,6 +116,7 @@ instance FromJSON PackageConstraints where
115116 pcBuildBenchmarks <- o .: "build-benchmarks"
116117 pcFlagOverrides <- Map.mapKeysWith const mkFlagName <$> o .: "flags"
117118 pcMaintainer <- o .:? "maintainer"
119+ pcEnableLibProfile <- fmap (fromMaybe False) (o .:? "library-profiling")
118120 return PackageConstraints {..}
119121
120122-- | The proposed plan from the requirements provided by contributors.
@@ -152,6 +154,7 @@ data ConstraintFile = ConstraintFile
152154 , cfSkippedBenchmarks :: Set PackageName
153155 , cfPackages :: Map Maintainer (Vector Dependency)
154156 , cfGithubUsers :: Map Text (Set Text)
157+ , cfSkippedLibProfiling :: Set PackageName
155158 }
156159
157160instance FromJSON ConstraintFile where
@@ -162,6 +165,7 @@ instance FromJSON ConstraintFile where
162165 cfExpectedTestFailures <- getPackages o "expected-test-failures"
163166 cfExpectedHaddockFailures <- getPackages o "expected-haddock-failures"
164167 cfSkippedBenchmarks <- getPackages o "skipped-benchmarks"
168+ cfSkippedLibProfiling <- getPackages o "skipped-profiling"
165169 cfPackages <- o .: "packages"
166170 >>= mapM (mapM toDep)
167171 . Map.mapKeysWith const Maintainer
@@ -196,6 +200,7 @@ toBC ConstraintFile {..} = do
196200 mpair = lookup name revmap
197201 pcMaintainer = fmap fst mpair
198202 pcVersionRange = maybe anyVersion snd mpair
203+ pcEnableLibProfile = not (name `member` cfSkippedLibProfiling)
199204 pcTests
200205 | name `member` cfSkippedTests = Don'tBuild
201206 | name `member` cfExpectedTestFailures = ExpectFailure