summaryrefslogtreecommitdiff
path: root/.gitlab/ci
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2022-11-14 15:20:22 +0000
committerKitware Robot <kwrobot@kitware.com>2022-11-14 10:20:32 -0500
commit4bf832086a137dcf92a2c27a54d35f6c0a717585 (patch)
tree8456f698479caf7eb99a969e8b26e01c8fc096b5 /.gitlab/ci
parente683a428f6658b226f84fd5fa26effef44c2e045 (diff)
parent09c1b1db078022096d9b671ebd5ad6bb7a4b52fd (diff)
downloadcmake-4bf832086a137dcf92a2c27a54d35f6c0a717585.tar.gz
Merge topic 'ci-windows-arm64'
09c1b1db07 gitlab-ci: Add windows-arm64 native jobs for Ninja and VS 61ebd7d083 ci: Download cmake on windows-arm64 93a5d89b42 ci: Teach cmake download script on Windows to branch on host architecture 1ccffcf0ea ci: Factor out helper to load python into environment on Windows 781303c0e2 ci: Factor out helper to load qt into environment on Windows b0d16c7f74 Tests: Fix CTest.UpdateGIT under repo-local defaultBranch config Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: Ben Boeckel <ben.boeckel@kitware.com> Merge-request: !7905
Diffstat (limited to '.gitlab/ci')
-rwxr-xr-x.gitlab/ci/cmake.ps114
-rw-r--r--.gitlab/ci/configure_windows_arm64_vs2022.cmake1
-rw-r--r--.gitlab/ci/configure_windows_arm64_vs2022_ninja.cmake7
-rwxr-xr-x.gitlab/ci/python-env.ps14
-rwxr-xr-x.gitlab/ci/qt-env.ps110
5 files changed, 34 insertions, 2 deletions
diff --git a/.gitlab/ci/cmake.ps1 b/.gitlab/ci/cmake.ps1
index 98aeae35b6..3efb67ab71 100755
--- a/.gitlab/ci/cmake.ps1
+++ b/.gitlab/ci/cmake.ps1
@@ -1,8 +1,18 @@
$erroractionpreference = "stop"
$version = "3.24.1"
-$sha256sum = "C1B17431A16337D517F7BA78C7067B6F143A12686CB8087F3DD32F3FA45F5AAE"
-$filename = "cmake-$version-windows-x86_64"
+
+if ("$env:PROCESSOR_ARCHITECTURE" -eq "AMD64") {
+ $sha256sum = "C1B17431A16337D517F7BA78C7067B6F143A12686CB8087F3DD32F3FA45F5AAE"
+ $platform = "windows-x86_64"
+} elseif ("$env:PROCESSOR_ARCHITECTURE" -eq "ARM64") {
+ $sha256sum = "D94683F3B0E63F6EF194C621194F6E26F3735EDA70750395E0F2BBEE4023FB95"
+ $platform = "windows-arm64"
+} else {
+ throw ('unknown PROCESSOR_ARCHITECTURE: ' + "$env:PROCESSOR_ARCHITECTURE")
+}
+
+$filename = "cmake-$version-$platform"
$tarball = "$filename.zip"
$outdir = $pwd.Path
diff --git a/.gitlab/ci/configure_windows_arm64_vs2022.cmake b/.gitlab/ci/configure_windows_arm64_vs2022.cmake
new file mode 100644
index 0000000000..c7d41ea1d4
--- /dev/null
+++ b/.gitlab/ci/configure_windows_arm64_vs2022.cmake
@@ -0,0 +1 @@
+include("${CMAKE_CURRENT_LIST_DIR}/configure_windows_vs_common.cmake")
diff --git a/.gitlab/ci/configure_windows_arm64_vs2022_ninja.cmake b/.gitlab/ci/configure_windows_arm64_vs2022_ninja.cmake
new file mode 100644
index 0000000000..722e009b11
--- /dev/null
+++ b/.gitlab/ci/configure_windows_arm64_vs2022_ninja.cmake
@@ -0,0 +1,7 @@
+# Qt host tools are not yet available natively on windows-arm64.
+set(CMake_TEST_GUI "OFF" CACHE BOOL "")
+set(BUILD_QtDialog "OFF" CACHE BOOL "")
+set(CMAKE_PREFIX_PATH "" CACHE STRING "")
+
+include("${CMAKE_CURRENT_LIST_DIR}/configure_windows_msvc_cxx_modules_common.cmake")
+include("${CMAKE_CURRENT_LIST_DIR}/configure_windows_vs_common_ninja.cmake")
diff --git a/.gitlab/ci/python-env.ps1 b/.gitlab/ci/python-env.ps1
new file mode 100755
index 0000000000..4e897d8dc6
--- /dev/null
+++ b/.gitlab/ci/python-env.ps1
@@ -0,0 +1,4 @@
+$pwdpath = $pwd.Path
+cmake -P .gitlab/ci/download_python3.cmake
+Set-Item -Force -Path "env:PATH" -Value "$pwdpath\.gitlab\python3;$env:PATH"
+python --version
diff --git a/.gitlab/ci/qt-env.ps1 b/.gitlab/ci/qt-env.ps1
new file mode 100755
index 0000000000..7eff55fc44
--- /dev/null
+++ b/.gitlab/ci/qt-env.ps1
@@ -0,0 +1,10 @@
+if ("$env:PROCESSOR_ARCHITECTURE" -eq "AMD64") {
+ $pwdpath = $pwd.Path
+ cmake -P .gitlab/ci/download_qt.cmake
+ Set-Item -Force -Path "env:PATH" -Value "$pwdpath\.gitlab\qt\bin;$env:PATH"
+ qmake -v
+} elseif ("$env:PROCESSOR_ARCHITECTURE" -eq "ARM64") {
+ # Qt host tools are not yet available natively on windows-arm64.
+} else {
+ throw ('unknown PROCESSOR_ARCHITECTURE: ' + "$env:PROCESSOR_ARCHITECTURE")
+}