build/pymake/tests/include-dynamic.mk
author Simon Sapin <simon.sapin@exyr.org>
Tue, 06 Jun 2017 08:13:39 -0700
changeset 1150023 c6508a9f0fb5f1648b37f299be7f3e481cb26c31
parent 47306 9d22ad64d6f062b1f7853f18e287fe2155de8020
permissions -rw-r--r--
servo: Merge #17185 - Fix some "unused" warnings (from servo:unused); r=emilio Source-Repo: https://github.com/servo/servo Source-Revision: 87005a0df33531995635728989c929572de429e7

$(shell \
if ! test -f include-dynamic.inc; then \
  echo "TESTVAR = oldval" > include-dynamic.inc; \
  sleep 2; \
  echo "TESTVAR = newval" > include-dynamic.inc.in; \
fi \
)

# before running the 'all' rule, we should be rebuilding include-dynamic.inc,
# because there is a rule to do so

all:
	test $(TESTVAR) = newval
	test "$(MAKE_RESTARTS)" = 1
	@echo TEST-PASS

include-dynamic.inc: include-dynamic.inc.in
	test "$(MAKE_RESTARTS)" = ""
	cp $< $@

include include-dynamic.inc