Commit 0aedb12d authored by Andrey Mokhov's avatar Andrey Mokhov
Browse files

Add pkgHaddockPath for finding haddock files.

parent d8112257
module Settings.TargetDirectory (
targetDirectory, targetPath
targetDirectory, targetPath, pkgHaddockPath
) where
import Base
import Util
import Stage
import Package
......@@ -14,3 +15,9 @@ targetDirectory = userTargetDirectory
-- Path to the target directory from GHC source root
targetPath :: Stage -> Package -> FilePath
targetPath stage pkg = pkgPath pkg -/- targetDirectory stage pkg
-- Relative path to a package haddock file, e.g.:
-- "libraries/array/dist-install/doc/html/array/array.haddock"
pkgHaddockPath :: Package -> FilePath
pkgHaddockPath pkg @ (Package name _) =
targetPath Stage1 pkg -/- "doc/html" -/- name -/- name <.> "haddock"
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment