Skip to content
Snippets Groups Projects
Commit 026f040a authored by Matthew Pickering's avatar Matthew Pickering Committed by Marge Bot
Browse files

packaging: Build manpage in separate directory to other documentation

We were installing two copies of the manpage:

* One useless one in the `share/doc` folder, because we copy the doc/
  folder into share/
* The one we deliberately installed into `share/man` etc

The solution is to build the manpage into the `manpage` directory when
building the bindist, and then just install it separately.

Fixes #23707
parent 8e699b23
No related branches found
No related tags found
No related merge requests found
......@@ -201,7 +201,7 @@ install_docs:
fi
MAN_SECTION := 1
MAN_PAGES := doc/users_guide/build-man/ghc.1
MAN_PAGES := manpage/ghc.1
.PHONY: install_man
install_man:
......
......@@ -246,6 +246,10 @@ bindistRules = do
-- reference. See #20802.
copyDirectory ("utils" -/- "completion") bindistFilesDir
-- Copy the manpage into the binary distribution
whenM (liftIO (IO.doesDirectoryExist (root -/- "manpage"))) $ do
copyDirectory (root -/- "manpage") bindistFilesDir
-- These scripts are only necessary in the configure/install
-- workflow which is not supported on windows.
-- TODO: Instead of guarding against windows, we could offer the
......
......@@ -43,7 +43,7 @@ archiveRoot :: FilePath
archiveRoot = docRoot -/- "archives"
manPageBuildPath :: FilePath
manPageBuildPath = docRoot -/- "users_guide/build-man/ghc.1"
manPageBuildPath = "manpage" -/- "ghc.1"
-- TODO: Get rid of this hack.
docContext :: Context
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment