Commit f9c199a1 authored by Simon Marlow's avatar Simon Marlow

install the Cabal docs, and make them show up in a binary distribution

parent d59e5356
......@@ -64,7 +64,7 @@ else
SUBDIRS_BUILD = gmp includes compat utils driver docs compiler rts
endif
SUBDIRS = gmp includes compat utils driver docs rts libraries compiler
SUBDIRS = gmp includes compat utils driver docs rts libraries compiler libraries/Cabal/doc
# Sanity check that all the boot libraries are in the tree, to catch
# failure to run darcs-all.
......@@ -309,6 +309,7 @@ binary-dist::
$(MAKE) -C utils binary-dist DOING_BIN_DIST=YES
$(MAKE) -C docs binary-dist DOING_BIN_DIST=YES
$(MAKE) -C libraries binary-dist DOING_BIN_DIST=YES
$(MAKE) -C libraries/Cabal/doc binary-dist DOING_BIN_DIST=YES
VARFILE=$(BIN_DIST_DIR)/Makefile-vars.in
......@@ -419,7 +420,7 @@ SRC_DIST_DIR=$(shell pwd)/$(SRC_DIST_NAME)
#
# Files to include in source distributions
#
SRC_DIST_DIRS += mk docs distrib bindisttest $(filter-out docs distrib,$(SUBDIRS))
SRC_DIST_DIRS += mk docs distrib bindisttest $(filter-out docs distrib libraries/Cabal/doc,$(SUBDIRS))
SRC_DIST_FILES += \
configure.ac config.guess config.sub configure \
aclocal.m4 README ANNOUNCE HACKING LICENSE Makefile install-sh \
......
......@@ -25,6 +25,7 @@ install::
$(MAKE) -C libraries install DOING_BIN_DIST=YES
$(MAKE) -C compiler install DOING_BIN_DIST=YES
$(MAKE) -C docs install-docs DOING_BIN_DIST=YES
$(MAKE) -C libraries/Cabal/doc install-docs DOING_BIN_DIST=YES
$(INSTALL_DATA) $(INSTALL_OPTS) extra-gcc-opts $(libdir)
install :: postinstall denounce
......
......@@ -266,9 +266,13 @@ endif
endif
ifneq "$(strip $(INSTALL_XML_DOC))" ""
ifeq "$(DOC_SUBDIR)" ""
DOC_SUBDIR=docs/$(XML_DOC)
endif
binary-dist::
$(MKDIRHIER) $(BIN_DIST_DIR)/docs/$(XML_DOC)
$(CP) Makefile $(BIN_DIST_DIR)/docs/$(XML_DOC)
$(MKDIRHIER) $(BIN_DIST_DIR)/$(DOC_SUBDIR)
$(CP) Makefile $(BIN_DIST_DIR)/$(DOC_SUBDIR)
ifneq "$(XMLDocWays)" ""
# TODO: The following could be an entry for an Obfuscated Makefile Contest...
......@@ -295,13 +299,13 @@ binary-dist:: $(foreach i,$(XMLDocWays),$(INSTALL_XML_DOC)$(patsubst %.html-no-c
binary-dist:: $(foreach i,$(XMLDocWays),binary-dist-docs-$i)
binary-dist-docs-html:
$(CP) -r $(INSTALL_XML_DOC) $(BIN_DIST_DIR)/docs/$(XML_DOC)/
$(CP) -r $(INSTALL_XML_DOC) $(BIN_DIST_DIR)/$(DOC_SUBDIR)
binary-dist-docs-html-no-chunks:
$(CP) $(INSTALL_XML_DOC).html $(BIN_DIST_DIR)/docs/$(XML_DOC)/
$(CP) $(INSTALL_XML_DOC).html $(BIN_DIST_DIR)/$(DOC_SUBDIR)/
binary-dist-docs-%:
$(CP) $(INSTALL_XML_DOC).$* $(BIN_DIST_DIR)/docs/$(XML_DOC)/
$(CP) $(INSTALL_XML_DOC).$* $(BIN_DIST_DIR)/$(DOC_SUBDIR)/
endif
endif
......
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