Skip to content

Commit 31e3f33

Browse files
committed
Expand ${pkgroot} variable when reading haddock-html field from ghc-pkg
This fixes #11217 No test, as it is difficult to test since you need to: 1. Ensure there is a package registration with ${pkgroot} 2. Check the existence of a certain link in the generated HTML.
1 parent 59c80b7 commit 31e3f33

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

Cabal/src/Distribution/Simple/Program/HcPkg.hs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -351,7 +351,7 @@ mungePackagePaths pkgroot pkginfo =
351351
, libraryDynDirs = mungePaths (libraryDynDirs pkginfo)
352352
, frameworkDirs = mungePaths (frameworkDirs pkginfo)
353353
, haddockInterfaces = mungePaths (haddockInterfaces pkginfo)
354-
, haddockHTMLs = mungeUrls (haddockHTMLs pkginfo)
354+
, haddockHTMLs = mungePaths (mungeUrls (haddockHTMLs pkginfo))
355355
}
356356
where
357357
mungePaths = map mungePath

changelog.d/pr-11218.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
synopsis: Fix links to installed documentation when running `cabal haddock`
2+
packages: Cabal
3+
prs: #11218
4+
5+
Links to installed documentation (i.e. for base) from generated haddock should
6+
now work.

0 commit comments

Comments
 (0)