summaryrefslogtreecommitdiff
path: root/.gitlab-ci.yml
diff options
context:
space:
mode:
authorJesse Natalie <jenatali@microsoft.com>2022-01-20 05:50:02 -0800
committerMarge Bot <emma+marge@anholt.net>2022-01-21 22:38:16 +0000
commit413f398cff6d1211650bd793caf5e51140e5e61e (patch)
treebddab03d38c2fc7b8578a13bd54d990b8a07102a /.gitlab-ci.yml
parent4d2937ff92c937f7bd47c60f368c1617f15425c3 (diff)
downloadmesa-413f398cff6d1211650bd793caf5e51140e5e61e.tar.gz
ci/windows: Use 2 container stages
The first container stage ("build") is for dependencies of the build. These are infrequently-changing things like Visual Studio, LLVM, git, and also meson. The second container stage ("test") currently depends on the first, and adds test dependencies like piglit. This lets us rev piglit without having to rebuild LLVM. Acked-by: Daniel Stone <daniels@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14637>
Diffstat (limited to '.gitlab-ci.yml')
-rw-r--r--.gitlab-ci.yml54
1 files changed, 46 insertions, 8 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 73c5159962a..52fa75b9458 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -568,40 +568,78 @@ debian/arm_test:
# then in the build stage by executing inside Docker.
.windows-docker-vs2019:
- extends:
- - .set-image
variables:
MESA_IMAGE: "$CI_REGISTRY_IMAGE/${MESA_IMAGE_PATH}:${MESA_IMAGE_TAG}"
- MESA_IMAGE_PATH: ${WINDOWS_X64_BUILD_PATH}
- MESA_IMAGE_TAG: ${WINDOWS_X64_BUILD_TAG}
MESA_UPSTREAM_IMAGE: "$CI_REGISTRY/$FDO_UPSTREAM_REPO/$MESA_IMAGE_PATH:${MESA_IMAGE_TAG}"
-windows_build_vs2019:
+.windows_container_build:
inherit:
default: false
extends:
- .container
- .windows-docker-vs2019
- stage: container
variables:
GIT_STRATEGY: fetch # we do actually need the full repository though
- timeout: 2h 30m # LLVM + piglit takes ages
+ MESA_BASE_IMAGE: None
tags:
- windows
- shell
- "1809"
- mesa
script:
- - .\.gitlab-ci\windows\mesa_container.ps1 $CI_REGISTRY $CI_REGISTRY_USER $CI_REGISTRY_PASSWORD $MESA_IMAGE $MESA_UPSTREAM_IMAGE
+ - .\.gitlab-ci\windows\mesa_container.ps1 $CI_REGISTRY $CI_REGISTRY_USER $CI_REGISTRY_PASSWORD $MESA_IMAGE $MESA_UPSTREAM_IMAGE ${DOCKERFILE} ${MESA_BASE_IMAGE}
+
+windows_build_vs2019:
+ inherit:
+ default: false
+ extends:
+ - .windows_container_build
+ variables:
+ MESA_IMAGE_PATH: &windows_build_image_path ${WINDOWS_X64_BUILD_PATH}
+ MESA_IMAGE_TAG: &windows_build_image_tag ${WINDOWS_X64_BUILD_TAG}
+ DOCKERFILE: Dockerfile_build
+ timeout: 2h 30m # LLVM takes ages
+
+windows_test_vs2019:
+ inherit:
+ default: false
+ extends:
+ - .windows_container_build
+ # Don't want the .container rules
+ - .ci-run-policy
+ variables:
+ MESA_IMAGE_PATH: &windows_test_image_path ${WINDOWS_X64_TEST_PATH}
+ MESA_IMAGE_TAG: &windows_test_image_tag ${WINDOWS_X64_BUILD_TAG}--${WINDOWS_X64_TEST_TAG}
+ DOCKERFILE: Dockerfile_test
+ # Right now this only needs the VS install to get DXIL.dll. Maybe see about decoupling this at some point
+ MESA_BASE_IMAGE_PATH: *windows_build_image_path
+ MESA_BASE_IMAGE_TAG: *windows_build_image_tag
+ MESA_BASE_IMAGE: "$CI_REGISTRY_IMAGE/${MESA_BASE_IMAGE_PATH}:${MESA_BASE_IMAGE_TAG}"
+ script:
+ - .\.gitlab-ci\windows\mesa_container.ps1 $CI_REGISTRY $CI_REGISTRY_USER $CI_REGISTRY_PASSWORD $MESA_IMAGE $MESA_UPSTREAM_IMAGE Dockerfile_test ${MESA_BASE_IMAGE}
+ needs:
+ - windows_build_vs2019
.use-windows_build_vs2019:
inherit:
default: false
extends: .windows-docker-vs2019
image: "$MESA_IMAGE"
+ variables:
+ MESA_IMAGE_PATH: *windows_build_image_path
+ MESA_IMAGE_TAG: *windows_build_image_tag
needs:
- windows_build_vs2019
+.use-windows_test_vs2019:
+ inherit:
+ default: false
+ extends: .windows-docker-vs2019
+ image: "$MESA_IMAGE"
+ variables:
+ MESA_IMAGE_PATH: *windows_test_image_path
+ MESA_IMAGE_TAG: *windows_test_image_tag
+
# Git archive