Fix Makefile build-arch target to use a single shell and correctly pass BASE_IMAGE_arch to docker build.

Reference: https://chatgpt.com/share/6936c5f9-5064-800f-8597-1cf3ccf7f42b
This commit is contained in:
Kevin Veen-Birkenbach
2025-12-08 13:35:20 +01:00
parent 15f3c1bcba
commit e6d041553b

View File

@@ -71,12 +71,19 @@ build:
-t "package-manager-test-$$distro" . || exit $$?; \
done
build-arch:
@base_image="$(BASE_IMAGE_arch)"; \
echo "Building test image 'package-manager-test-arch' (BASE_IMAGE=$$base_image)..."; \
docker build \
--build-arg BASE_IMAGE="$$base_image" \
-t "package-manager-test-arch" . || exit $$?;
# ------------------------------------------------------------
# Test targets
# ------------------------------------------------------------
# Unit tests: only in Arch container (fastest feedback)
test-unit: build
test-unit: build-arch
@echo "============================================================"
@echo ">>> Running UNIT tests in Arch container"
@echo "============================================================"