git.iko.soy/typeable/cabal2nix
on master help sign in
Merge pull request #264 from expipiplus1/bench

Use benchmark instead of bench

commit08a0c317108945939ce98549e09f7450e34d7b22 authorPeter Simons <simons@cryp.to> dateTue 28 Feb 2017, 14:35 (10 years ago) parentc75a2a1e36a23a
3 files changed+7−7
src/Distribution/Nixpkgs/Haskell/Derivation.hs+5−5 src/Distribution/Nixpkgs/Haskell/FromCabal.hs+1−1 src/Distribution/Nixpkgs/Haskell/FromCabal/Normalize.hs+1−1
src/Distribution/Nixpkgs/Haskell/Derivation.hs+5−5
@@ -8,7 +8,7 @@ module Distribution.Nixpkgs.Haskell.Derivation
88 , extraFunctionArgs, libraryDepends, executableDepends, testDepends, configureFlags
99 , cabalFlags, runHaddock, jailbreak, doCheck, testTarget, hyperlinkSource, enableSplitObjs
1010 , enableLibraryProfiling, enableExecutableProfiling, phaseOverrides, editedCabalFile, metaSection
11− , dependencies, setupDepends, benchDepends
11+ , dependencies, setupDepends, benchmarkDepends
1212 )
1313 where
1414
@@ -43,7 +43,7 @@ data Derivation = MkDerivation
4343 , _libraryDepends :: BuildInfo
4444 , _executableDepends :: BuildInfo
4545 , _testDepends :: BuildInfo
46− , _benchDepends :: BuildInfo
46+ , _benchmarkDepends :: BuildInfo
4747 , _configureFlags :: Set String
4848 , _cabalFlags :: FlagAssignment
4949 , _runHaddock :: Bool
@@ -72,7 +72,7 @@ nullDerivation = MkDerivation
7272 , _libraryDepends = error "undefined Derivation.libraryDepends"
7373 , _executableDepends = error "undefined Derivation.executableDepends"
7474 , _testDepends = error "undefined Derivation.testDepends"
75− , _benchDepends = error "undefined Derivation.benchDepends"
75+ , _benchmarkDepends = error "undefined Derivation.benchmarkDepends"
7676 , _configureFlags = error "undefined Derivation.configureFlags"
7777 , _cabalFlags = error "undefined Derivation.cabalFlags"
7878 , _runHaddock = error "undefined Derivation.runHaddock"
@@ -90,7 +90,7 @@ nullDerivation = MkDerivation
9090
9191makeLenses ''Derivation
9292
93−makeLensesFor [("_setupDepends", "dependencies"), ("_libraryDepends", "dependencies"), ("_executableDepends", "dependencies"), ("_testDepends", "dependencies"), ("_benchDepends", "dependencies")] ''Derivation
93+makeLensesFor [("_setupDepends", "dependencies"), ("_libraryDepends", "dependencies"), ("_executableDepends", "dependencies"), ("_testDepends", "dependencies"), ("_benchmarkDepends", "dependencies")] ''Derivation
9494
9595instance Package Derivation where
9696 packageId = view pkgid
@@ -113,7 +113,7 @@ instance Pretty Derivation where
113113 , onlyIf (_libraryDepends /= mempty) $ pPrintBuildInfo "library" _libraryDepends
114114 , onlyIf (_executableDepends /= mempty) $ pPrintBuildInfo "executable" _executableDepends
115115 , onlyIf (_testDepends /= mempty) $ pPrintBuildInfo "test" _testDepends
116− , onlyIf (_benchDepends /= mempty) $ pPrintBuildInfo "bench" _benchDepends
116+ , onlyIf (_benchmarkDepends /= mempty) $ pPrintBuildInfo "benchmark" _benchmarkDepends
117117 , boolattr "enableLibraryProfiling" _enableLibraryProfiling _enableLibraryProfiling
118118 , boolattr "enableExecutableProfiling" _enableExecutableProfiling _enableExecutableProfiling
119119 , boolattr "enableSplitObjs" (not _enableSplitObjs) _enableSplitObjs
src/Distribution/Nixpkgs/Haskell/FromCabal.hs+1−1
@@ -63,7 +63,7 @@ fromPackageDescription haskellResolver nixpkgsResolver missingDeps flags (Packag
6363 & libraryDepends .~ maybe mempty (convertBuildInfo . libBuildInfo) library
6464 & executableDepends .~ mconcat (map (convertBuildInfo . buildInfo) executables)
6565 & testDepends .~ mconcat (map (convertBuildInfo . testBuildInfo) testSuites)
66− & benchDepends .~ mconcat (map (convertBuildInfo . benchmarkBuildInfo) benchmarks)
66+ & benchmarkDepends .~ mconcat (map (convertBuildInfo . benchmarkBuildInfo) benchmarks)
6767 & Nix.setupDepends .~ maybe mempty convertSetupBuildInfo setupBuildInfo
6868 & configureFlags .~ mempty
6969 & cabalFlags .~ flags
src/Distribution/Nixpkgs/Haskell/FromCabal/Normalize.hs+1−1
@@ -17,7 +17,7 @@ normalize drv = drv
1717 & over libraryDepends (normalizeBuildInfo (packageName drv))
1818 & over executableDepends (normalizeBuildInfo (packageName drv))
1919 & over testDepends (normalizeBuildInfo (packageName drv))
20− & over benchDepends (normalizeBuildInfo (packageName drv))
20+ & over benchmarkDepends (normalizeBuildInfo (packageName drv))
2121 & over metaSection normalizeMeta
2222 & over cabalFlags normalizeCabalFlags
2323 & jailbreak %~ (&& (packageName drv /= PackageName "jailbreak-cabal"))