Commit df77da92 authored by Simon Marlow's avatar Simon Marlow

tidy up the binary-dist targets a bit more

parent 8e02b4ab
...@@ -365,13 +365,6 @@ binary-dist:: ...@@ -365,13 +365,6 @@ binary-dist::
done done
endif endif
# Jiggle the files around to make a valid Windows distribution if necessary
ifeq "$(TARGETPLATFORM)" "i386-unknown-mingw32"
binary-dist :: fiddle-binary-dist
endif
fiddle-binary-dist:
cd $(BIN_DIST_TMPDIR)/$(BIN_DIST_NAME) && ../distrib/prep-bin-dist-mingw
.PHONY: binary-dist-doc-% .PHONY: binary-dist-doc-%
BIN_DIST_LIBDIR=$(BIN_DIST_DIR)/libraries BIN_DIST_LIBDIR=$(BIN_DIST_DIR)/libraries
...@@ -396,26 +389,34 @@ $(BINARY_DIST_LIBRARY_RULES): binary-dist-lib-%: ...@@ -396,26 +389,34 @@ $(BINARY_DIST_LIBRARY_RULES): binary-dist-lib-%:
\( \( -name "*.o" -o -name "*.p_o" \) -a \! -name "HS*" \) \ \( \( -name "*.o" -o -name "*.p_o" \) -a \! -name "HS*" \) \
-exec rm {} \; -exec rm {} \;
# Jiggle the files around to make a valid Windows distribution if necessary
ifeq "$(TARGETPLATFORM)" "i386-unknown-mingw32"
binary-dist :: fiddle-binary-dist
endif
.PHONY: fiddle-binary-dist
fiddle-binary-dist:
cd $(BIN_DIST_TMPDIR)/$(BIN_DIST_NAME) && ../distrib/prep-bin-dist-mingw
# Tar up the distribution and build a manifest # Tar up the distribution and build a manifest
binary-dist :: tar-binary-dist binary-dist :: tar-binary-dist
.PHONY: tar-binary-dist
tar-binary-dist: tar-binary-dist:
( cd $(BIN_DIST_TOPDIR); tar cf - $(BIN_DIST_NAME) | bzip2 >$(BIN_DIST_TARBALL) ) ( cd $(BIN_DIST_TOPDIR); tar cf - $(BIN_DIST_NAME) | bzip2 >$(BIN_DIST_TARBALL) )
( cd $(BIN_DIST_TOPDIR); bunzip2 -c $(BIN_DIST_TARBALL) | tar tf - | sed "s/^ghc-$(ProjectVersion)/fptools/" | sort >bin-manifest-$(ProjectVersion) ) ( cd $(BIN_DIST_TOPDIR); bunzip2 -c $(BIN_DIST_TARBALL) | tar tf - | sed "s/^ghc-$(ProjectVersion)/fptools/" | sort >bin-manifest-$(ProjectVersion) )
# Upload the distribution and documentation # Upload the distribution and documentation
ifneq "$(PublishLocation)" "" ifneq "$(PublishLocation)" ""
binary-dist :: binary-dist :: publish-binary-dist
$(MAKE) publish-binary-dist
endif endif
.PHONY: publish-binary-dist
publish-binary-dist : publish-binary-dist :
@for i in 0 1 2 3 4 5 6 7 8 9; do \ @for i in 0 1 2 3 4 5 6 7 8 9; do \
echo "Try $$i: $(PublishCp) $(BIN_DIST_TARBALL) $(PublishLocation)"; \ echo "Try $$i: $(PublishCp) $(BIN_DIST_TARBALL) $(PublishLocation)"; \
if $(PublishCp) $(BIN_DIST_TARBALL) $(PublishLocation); then break; fi\ if $(PublishCp) $(BIN_DIST_TARBALL) $(PublishLocation); then break; fi\
done done
$(PublishCp) -r $(BIN_DIST_DIR)/share/html/* $(PublishLocation)/docs $(PublishCp) -r $(BIN_DIST_DIR)/share/html/* $(PublishLocation)/docs
endif
binary-dist:: binary-dist::
......
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