Commit 6f36790b authored by ian@well-typed.com's avatar ian@well-typed.com

Add an echo target to the build system

parent d8dd3cf9
......@@ -45,7 +45,7 @@ endif
include mk/custom-settings.mk
# No need to update makefiles for these targets:
REALGOALS=$(filter-out binary-dist binary-dist-prep bootstrapping-files framework-pkg clean clean_% distclean maintainer-clean show help test fulltest,$(MAKECMDGOALS))
REALGOALS=$(filter-out binary-dist binary-dist-prep bootstrapping-files framework-pkg clean clean_% distclean maintainer-clean show echo help test fulltest,$(MAKECMDGOALS))
# configure touches certain files even if they haven't changed. This
# can mean a lot of unnecessary recompilation after a re-configure, so
......@@ -93,7 +93,7 @@ clean distclean maintainer-clean:
$(filter clean_%, $(MAKECMDGOALS)) : clean_% :
$(MAKE) -r --no-print-directory -f ghc.mk $@ CLEANING=YES
bootstrapping-files show:
bootstrapping-files show echo:
$(MAKE) -r --no-print-directory -f ghc.mk $@
ifeq "$(darwin_TARGET_OS)" "1"
......
......@@ -110,6 +110,14 @@ comma=,
show:
@echo '$(VALUE)="$($(VALUE))"'
# echo is used by the nightly builders to query the build system for
# information.
# Using printf means that we don't get a trailing newline. We escape
# backslashes and double quotes in the string to protect them from the
# shell, and percent signs to protect them from printf.
echo:
@printf "$(subst %,%%,$(subst ",\",$(subst \,\\\\,$($(VALUE)))))"
# -----------------------------------------------------------------------------
# Include subsidiary build-system bits
......
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