summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
Diffstat (limited to 'mk')
-rw-r--r--mk/cabal.mk3
-rw-r--r--mk/config.mk.in9
-rw-r--r--mk/install.mk17
3 files changed, 8 insertions, 21 deletions
diff --git a/mk/cabal.mk b/mk/cabal.mk
index 98b985bb97..1ae6cba4b8 100644
--- a/mk/cabal.mk
+++ b/mk/cabal.mk
@@ -1,5 +1,6 @@
include $(TOP)/mk/cabal-flags.mk
+include $(TOP)/mk/bindist.mk
# XXX We would like to turn this on, but Cabal generates paths files
# that are not -Wall clean!
@@ -60,5 +61,3 @@ ifneq "$(EXTRA_CLEAN)" ""
$(RM) -f $(EXTRA_CLEAN)
endif
-# XXX fix binary-dist
-
diff --git a/mk/config.mk.in b/mk/config.mk.in
index 839fe29c15..3812475aaf 100644
--- a/mk/config.mk.in
+++ b/mk/config.mk.in
@@ -535,10 +535,15 @@ endif
# On Windows this is a c:/foo/bar style path.
FPTOOLS_TOP_ABS = @hardtop@
-BIN_DIST_NAME=ghc-$(ProjectVersion)
BIN_DIST_TOPDIR_ABS=$(FPTOOLS_TOP_ABS)
BIN_DIST_DIR=$(BIN_DIST_TOPDIR_ABS)/$(BIN_DIST_NAME)
-BIN_DIST_TARBALL=$(FPTOOLS_TOP_ABS)/$(BIN_DIST_NAME)-$(TARGETPLATFORM).tar.bz2
+
+BIN_DIST_NAME=ghc-$(ProjectVersion)
+BIN_DIST_TAR=$(FPTOOLS_TOP_ABS)/$(BIN_DIST_NAME)-$(TARGETPLATFORM).tar
+BIN_DIST_TAR_BZ2=$(BIN_DIST_TAR).bz2
+BIN_DIST_PREP_DIR=$(FPTOOLS_TOP_ABS)/bindist-prep
+BIN_DIST_PREP=$(BIN_DIST_PREP_DIR)/$(BIN_DIST_NAME)
+BIN_DIST_LIST=$(FPTOOLS_TOP_ABS)/bindist-list
# Definition of installation directories, we don't use half of these, but since
# the configure script has them on offer while passing through, we might as well
diff --git a/mk/install.mk b/mk/install.mk
index dd8dfc4946..41b312c3c5 100644
--- a/mk/install.mk
+++ b/mk/install.mk
@@ -270,10 +270,6 @@ ifeq "$(DOC_SUBDIR)" ""
DOC_SUBDIR=docs/$(XML_DOC)
endif
-binary-dist::
- $(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...
install-docs:: $(foreach i,$(XMLDocWays),$(INSTALL_XML_DOC)$(patsubst %.html-no-chunks,%.html,$(patsubst %.html,%/index.html,.$(i))))
@@ -293,19 +289,6 @@ install-docs-html-no-chunks:
install-docs-%:
$(INSTALL_DIR) $(DESTDIR)$($*dir)
$(INSTALL_DATA) $(INSTALL_OPTS) $(INSTALL_XML_DOC).$* $(DESTDIR)$($*dir)
-
-binary-dist:: $(foreach i,$(XMLDocWays),$(INSTALL_XML_DOC)$(patsubst %.html-no-chunks,%.html,$(patsubst %.html,%/index.html,.$(i))))
-
-binary-dist:: $(foreach i,$(XMLDocWays),binary-dist-docs-$i)
-
-binary-dist-docs-html:
- $(CP) -r $(INSTALL_XML_DOC) $(BIN_DIST_DIR)/$(DOC_SUBDIR)
-
-binary-dist-docs-html-no-chunks:
- $(CP) $(INSTALL_XML_DOC).html $(BIN_DIST_DIR)/$(DOC_SUBDIR)/
-
-binary-dist-docs-%:
- $(CP) $(INSTALL_XML_DOC).$* $(BIN_DIST_DIR)/$(DOC_SUBDIR)/
endif
endif