[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 5/7] configure: store container engine in config-host.mak
From: |
Paolo Bonzini |
Subject: |
[PATCH 5/7] configure: store container engine in config-host.mak |
Date: |
Tue, 7 Jun 2022 11:40:29 +0200 |
In preparation for removing $(DOCKER_SCRIPT) from the tests/tcg configuration
files, have Make use the same container engine that had been probed at
configure time.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
configure | 11 ++++++++---
tests/docker/Makefile.include | 2 +-
2 files changed, 9 insertions(+), 4 deletions(-)
diff --git a/configure b/configure
index 6b38b0815c..0fd5a3cfad 100755
--- a/configure
+++ b/configure
@@ -1819,9 +1819,11 @@ esac
container="no"
if test $use_containers = "yes"; then
- if has "docker" || has "podman"; then
- container=$($python $source_path/tests/docker/docker.py probe)
- fi
+ case $($python $source_path/tests/docker/docker.py probe) in
+ *docker) container=docker ;;
+ podman) container=podman ;;
+ no) container=no ;;
+ esac
fi
# cross compilers defaults, can be overridden with --cross-cc-ARCH
@@ -2401,6 +2403,9 @@ if test -n "$gdb_bin"; then
fi
fi
+if test "$container" != no; then
+ echo "ENGINE=$container" >> $config_host_mak
+fi
echo "ROMS=$roms" >> $config_host_mak
echo "MAKE=$make" >> $config_host_mak
echo "PYTHON=$python" >> $config_host_mak
diff --git a/tests/docker/Makefile.include b/tests/docker/Makefile.include
index e68f91b853..d9b6ab7b41 100644
--- a/tests/docker/Makefile.include
+++ b/tests/docker/Makefile.include
@@ -14,7 +14,7 @@ DOCKER_DEFAULT_REGISTRY :=
registry.gitlab.com/qemu-project/qemu
endif
DOCKER_REGISTRY := $(if $(REGISTRY),$(REGISTRY),$(DOCKER_DEFAULT_REGISTRY))
-ENGINE := auto
+ENGINE ?= auto
DOCKER_SCRIPT=$(SRC_PATH)/tests/docker/docker.py --engine $(ENGINE)
CUR_TIME := $(shell date +%Y-%m-%d-%H.%M.%S.$$$$)
--
2.36.1
- [PATCH 0/7] More tests/tcg cleanups, Paolo Bonzini, 2022/06/07
- [PATCH 3/7] configure: allow more host/target combos to use the host compiler, Paolo Bonzini, 2022/06/07
- [PATCH 4/7] configure: move tests/tcg/Makefile.prereqs to root build directory, Paolo Bonzini, 2022/06/07
- [PATCH 6/7] tests: simplify Makefile invocation for tests/tcg, Paolo Bonzini, 2022/06/07
- [PATCH 5/7] configure: store container engine in config-host.mak,
Paolo Bonzini <=
- [PATCH 2/7] build: include pc-bios/ part in the ROMS variable, Paolo Bonzini, 2022/06/07
- [PATCH 1/7] meson: put cross compiler info in a separate section, Paolo Bonzini, 2022/06/07
- [PATCH 7/7] tests/tcg: remove -f from Makefile invocation, Paolo Bonzini, 2022/06/07
- Re: [PATCH 0/7] More tests/tcg cleanups, Paolo Bonzini, 2022/06/07