Skip to content

Commit

Permalink
auto merge of #19896 : ktossell/rust/allow-nodoc-install, r=alexcrichton
Browse files Browse the repository at this point in the history
If you configure with `--disable-docs`, the `doc` directory does not get generated, so the
`cp -r doc dist/` step fails when you `make dist{,-tar-bins,-doc}` or `make install`.
  • Loading branch information
bors committed Dec 18, 2014
2 parents f9a4849 + cbf80f3 commit 99d6956
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions mk/dist.mk
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ dist-install-dir-$(1): prepare-base-dir-$(1) docs compiler-docs
$$(Q)$$(PREPARE_MAN_CMD) $$(S)LICENSE-APACHE $$(PREPARE_DEST_DIR)
$$(Q)$$(PREPARE_MAN_CMD) $$(S)LICENSE-MIT $$(PREPARE_DEST_DIR)
$$(Q)$$(PREPARE_MAN_CMD) $$(S)README.md $$(PREPARE_DEST_DIR)
$$(Q)cp -r doc $$(PREPARE_DEST_DIR)
$$(Q)[ ! -d doc ] || cp -r doc $$(PREPARE_DEST_DIR)

dist/$$(PKG_NAME)-$(1).tar.gz: dist-install-dir-$(1)
@$(call E, build: $$@)
Expand Down Expand Up @@ -312,9 +312,17 @@ MAYBE_DIST_TAR_SRC=dist-tar-src
MAYBE_DISTCHECK_TAR_SRC=distcheck-tar-src
endif

dist: $(MAYBE_DIST_TAR_SRC) dist-osx dist-tar-bins dist-docs
ifneq ($(CFG_DISABLE_DOCS),)
MAYBE_DIST_DOCS=
MAYBE_DISTCHECK_DOCS=
else
MAYBE_DIST_DOCS=dist-docs
MAYBE_DISTCHECK_DOCS=distcheck-docs
endif

dist: $(MAYBE_DIST_TAR_SRC) dist-osx dist-tar-bins $(MAYBE_DIST_DOCS)

distcheck: $(MAYBE_DISTCHECK_TAR_SRC) distcheck-osx distcheck-tar-bins distcheck-docs
distcheck: $(MAYBE_DISTCHECK_TAR_SRC) distcheck-osx distcheck-tar-bins $(MAYBE_DISTCHECK_DOCS)
$(Q)rm -Rf tmp/distcheck
@echo
@echo -----------------------------------------------
Expand Down

0 comments on commit 99d6956

Please sign in to comment.