docker: print warning if EXECUTABLE is not set when building debootstrap image
authorSascha Silbe <silbe@linux.vnet.ibm.com>
Tue, 6 Sep 2016 20:05:48 +0000 (22:05 +0200)
committerFam Zheng <famz@redhat.com>
Thu, 8 Sep 2016 11:56:34 +0000 (19:56 +0800)
Building the debian-debootstrap image will usually fail if EXECUTABLE
isn't set (when using the Makefile). Warn the user in this case so
they know why it's failing.

Signed-off-by: Sascha Silbe <silbe@linux.vnet.ibm.com>
Message-Id: <1473192351-601-6-git-send-email-silbe@linux.vnet.ibm.com>
Signed-off-by: Fam Zheng <famz@redhat.com>
tests/docker/Makefile.include

index 1b20db09e2e4547a6edaf9045f0abf85d9cef227..19d4cc7077a20cd63f4d6d517cdd96c63d0e29b5 100644 (file)
@@ -44,6 +44,9 @@ docker-image: ${DOCKER_TARGETS}
 
 # General rule for building docker images
 docker-image-%: $(DOCKER_FILES_DIR)/%.docker
+       @if test "$@" = docker-image-debian-bootstrap -a -z "$(EXECUTABLE)"; then \
+               echo WARNING: EXECUTABLE is not set, debootstrap may fail. 2>&1 ; \
+       fi
        $(call quiet-command,\
                $(SRC_PATH)/tests/docker/docker.py build qemu:$* $< \
                $(if $V,,--quiet) $(if $(NOCACHE),--no-cache) \