diff mbox series

[v6,48/49] tests/docker: prevent sub-makes re-building debian-sid

Message ID 20180608123307.24773-49-alex.bennee@linaro.org
State New
Headers show
Series fix building of tests/tcg | expand

Commit Message

Alex Bennée June 8, 2018, 12:33 p.m. UTC
This is a bit of a hack but having ensured Debian SID is built at
least once in the top-level we don't need to do it over and over
again. Perhaps a better solution would be to have docker.py spit out
the dependency if a base image is too old?

Signed-off-by: Alex Bennée <alex.bennee@linaro.org>

---
 tests/docker/Makefile.include | 6 +++++-
 tests/tcg/Makefile.include    | 1 +
 2 files changed, 6 insertions(+), 1 deletion(-)

-- 
2.17.1
diff mbox series

Patch

diff --git a/tests/docker/Makefile.include b/tests/docker/Makefile.include
index 78568d7c61..3393e9f97d 100644
--- a/tests/docker/Makefile.include
+++ b/tests/docker/Makefile.include
@@ -63,8 +63,12 @@  docker-image-debian-win64-cross: docker-image-debian8-mxe
 
 # Debian SID images - we are tracking a rolling distro so we want to
 # force a re-build of the base image if we ever need to build one of
-# its children.
+# its children. However when doing check-tcg we ensure everything is
+# built at top-level make so we can dispense with NOCACHE here to
+# avoid excessive re-builds.
+ifneq ($(SUBMAKE_NOCACHE_HACK),y)
 docker-image-debian-sid: NOCACHE=1
+endif
 
 docker-image-debian-alpha-cross: docker-image-debian-sid
 docker-image-debian-hppa-cross: docker-image-debian-sid
diff --git a/tests/tcg/Makefile.include b/tests/tcg/Makefile.include
index 4851df0951..951f40c28d 100644
--- a/tests/tcg/Makefile.include
+++ b/tests/tcg/Makefile.include
@@ -39,6 +39,7 @@  ifeq ($(HAVE_USER_DOCKER)$(GUEST_BUILD),y)
 ifneq ($(DOCKER_IMAGE),)
 
 # We also need the Docker make rules to depend on
+SUBMAKE_NOCACHE_HACK=y
 include $(SRC_PATH)/tests/docker/Makefile.include
 
 DOCKER_COMPILE_CMD="$(DOCKER_SCRIPT) cc --user $(shell id -u) \