summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authorThomas Miedema <thomasmiedema@gmail.com>2016-01-29 20:30:47 +0100
committerThomas Miedema <thomasmiedema@gmail.com>2016-01-31 16:02:14 +0100
commitb61f5f734d08fe9cdca3ac06560fc15e97aa77ab (patch)
tree85a766844cfb8e5b0e6a48073fb5cee7171bcf44 /mk
parent2fbf370b953634716d3c0ad7020c29f06fdd68f4 (diff)
downloadhaskell-b61f5f734d08fe9cdca3ac06560fc15e97aa77ab.tar.gz
Put docs in /usr/share/doc/ghc-<version>
`make install` puts libraries in a direcory containing the version number. Do the same for the docs, such that multiple installs can live side-by-side. Delete unused ghcdocdir. Test Plan: ``` ./boot ./configure make show! VALUE=docdir ``` Reviewed by: bgamari Differential Revision: https://phabricator.haskell.org/D1868 GHC Trac Issues: #11354
Diffstat (limited to 'mk')
-rw-r--r--mk/install.mk.in11
1 files changed, 4 insertions, 7 deletions
diff --git a/mk/install.mk.in b/mk/install.mk.in
index e404397647..aa3afea2b9 100644
--- a/mk/install.mk.in
+++ b/mk/install.mk.in
@@ -40,7 +40,7 @@
#
# NOTE: The default e.g. ${docdir} above means that autoconf substitutes the
# string "${docdir}", not the value of docdir! This is crucial for the GNU
-# coding standards.
+# coding standards. See Trac #1924.
define set_default
# $1 = variable to set
@@ -52,9 +52,6 @@ $1 = $2
endif
endef
-# This gets used in the default docdir when autoconf >= 2.60 is used
-PACKAGE_TARNAME = @PACKAGE_TARNAME@
-
prefix = @prefix@
datarootdir = @datarootdir@
@@ -67,8 +64,10 @@ libdir = @libdir@
includedir = @includedir@
mandir = @mandir@
+# Note that `./configure --docdir=/foo/bar` should work.
docdir = @docdir@
-$(eval $(call set_default,docdir,$${datarootdir}/doc/ghc))
+PACKAGE_TARNAME = ghc-${ProjectVersion}
+$(eval $(call set_default,docdir,$${datarootdir}/doc/$${PACKAGE_TARNAME}))
htmldir = @htmldir@
dvidir = @dvidir@
@@ -94,14 +93,12 @@ pdfdir = $(docdir)
psdir = $(docdir)
ghclibdir = $(libdir)
-ghcdocdir = $(datarootdir)/doc
else
# Unix: override libdir and datadir to put ghc-specific stuff in
# a subdirectory with the version number included.
ghclibdir = $(libdir)/$(CrossCompilePrefix)ghc-$(ProjectVersion)
-ghcdocdir = $(datarootdir)/doc/ghc
endif
ghclibexecdir = $(ghclibdir)