Skip to content
This repository has been archived by the owner on Aug 2, 2020. It is now read-only.

Commit

Permalink
Add an explicit dependency on pkgDataFile to make sure GhcCabal hscol…
Browse files Browse the repository at this point in the history
…our is run after GhcCabal configure.
  • Loading branch information
snowleopard committed Dec 20, 2015
1 parent 5c42b58 commit 0c9d7d8
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/Rules/Documentation.hs
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ import Settings
-- All of them go into the 'doc' subdirectory. Pedantically tracking all built
-- files in the Shake databases seems fragile and unnecesarry.
buildPackageDocumentation :: Resources -> PartialTarget -> Rules ()
buildPackageDocumentation _ target @ (PartialTarget stage package) =
let cabalFile = pkgCabalFile package
haddockFile = pkgHaddockFile package
buildPackageDocumentation _ target @ (PartialTarget stage pkg) =
let cabalFile = pkgCabalFile pkg
haddockFile = pkgHaddockFile pkg
in when (stage == Stage1) $ do
haddockFile %> \file -> do
srcs <- interpretPartial target getPackageSources
Expand All @@ -23,7 +23,7 @@ buildPackageDocumentation _ target @ (PartialTarget stage package) =

-- HsColour sources
whenM (specified HsColour) $ do
need [cabalFile]
need [cabalFile, pkgDataFile stage pkg ]
build $ fullTarget target GhcCabalHsColour [cabalFile] []

-- Build Haddock documentation
Expand Down

0 comments on commit 0c9d7d8

Please sign in to comment.