Skip to content
Permalink
Browse files
Revert "Disable Haddock phase for packages with internal libraries."
Cabal does the right thing since 2.4.0.0 (haskell/cabal#5253)

This reverts commit 7017487.
  • Loading branch information
shlevy committed Feb 12, 2019
1 parent d974819 commit 04feef673cc2c739a9cb8a464b60c1f1aa557e90
Showing with 1 addition and 153 deletions.
  1. +1 −6 src/Distribution/Nixpkgs/Haskell/FromCabal.hs
  2. +0 −130 test/golden-test-cases/haddock-library.cabal
  3. +0 −17 test/golden-test-cases/haddock-library.nix.golden
@@ -88,7 +88,7 @@ fromPackageDescription haskellResolver nixpkgsResolver missingDeps flags Package
& Nix.setupDepends .~ maybe mempty convertSetupBuildInfo setupBuildInfo
& configureFlags .~ mempty
& cabalFlags .~ flags
& runHaddock .~ doHaddockPhase
& runHaddock .~ maybe True (not . null . exposedModules) library
& jailbreak .~ False
& doCheck .~ True
& doBenchmark .~ False
@@ -150,11 +150,6 @@ fromPackageDescription haskellResolver nixpkgsResolver missingDeps flags Package
internalLibNames :: [PackageName]
internalLibNames = fmap unqualComponentNameToPackageName . catMaybes $ libName <$> subLibraries

doHaddockPhase :: Bool
doHaddockPhase | not (null internalLibNames) = False
| Just l <- library = not (null (exposedModules l))
| otherwise = True

convertBuildInfo :: Cabal.BuildInfo -> Nix.BuildInfo
convertBuildInfo Cabal.BuildInfo {..} | not buildable = mempty
convertBuildInfo Cabal.BuildInfo {..} = mempty

This file was deleted.

This file was deleted.

0 comments on commit 04feef6

Please sign in to comment.