diff options
Diffstat (limited to 'hadrian/src/Rules/Documentation.hs')
-rw-r--r-- | hadrian/src/Rules/Documentation.hs | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/hadrian/src/Rules/Documentation.hs b/hadrian/src/Rules/Documentation.hs index 3c31823889..27aece61d2 100644 --- a/hadrian/src/Rules/Documentation.hs +++ b/hadrian/src/Rules/Documentation.hs @@ -78,6 +78,8 @@ needDocDeps = do , ghci , libiserv , compiler + , ghcHeap + , templateHaskell ] need templatedCabalFiles @@ -102,8 +104,6 @@ documentationRules = do "docs" ~> do root <- buildRoot - needDocDeps - doctargets <- ghcDocs =<< flavour let html = htmlRoot -/- "index.html" -- also implies "docs-haddock" archives = map pathArchive docPaths @@ -203,6 +203,9 @@ buildSphinxHtml path = do root -/- htmlRoot -/- path -/- "index.html" %> \file -> do let dest = takeDirectory file rstFilesDir = pathPath path + + needDocDeps + rstFiles <- getDirectoryFiles rstFilesDir ["**/*.rst"] need (map (rstFilesDir -/-) rstFiles) build $ target docContext (Sphinx HtmlMode) [pathPath path] [dest] @@ -314,6 +317,9 @@ buildSphinxPdf :: FilePath -> Rules () buildSphinxPdf path = do root <- buildRootRules root -/- pdfRoot -/- path <.> "pdf" %> \file -> do + + needDocDeps + withTempDir $ \dir -> do let rstFilesDir = pathPath path rstFiles <- getDirectoryFiles rstFilesDir ["**/*.rst"] |