Skip to contentSkip to conversation

automation/gitlab: introduce macOS build jobs

PATCH In review Roger Pau Monne 2 participants 3 messages Apr 23 – May 5

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 automation/gitlab: introduce macOS build jobs

With the imminent decommission of CirrusCI we will lose the limited macOS build testing done there. Introduce two Gitlab macOS build jobs that reproduce the ones present on CirrusCI.

According to the "Community programs" Gitlab documentation [0] we get 50,000 compute minutes per month. The arm64 job takes ~1m 15s, and the x86_64 one ~2m. I think it's likely enough given the amount of minutes we have available. We might need to reconsider if we add more tasks that consume compute minutes.

[0] https://docs.gitlab.com/subscriptions/community_programs/#gitlab-for-open-source

---
Example jobs at:

https://gitlab.com/xen-project/hardware/xen-staging/-/jobs/14064832403
https://gitlab.com/xen-project/hardware/xen-staging/-/jobs/14064832402

---
 automation/gitlab-ci/build.yaml | 30 ++++++++++++++++++++++++++++++
 1 file changed, 30 insertions(+)
automation/gitlab-ci/build.yaml +30 -0
index eff96beaa5c3..463ed2f96d86 100644
@@ -815,3 +815,33 @@ debian-13-riscv64-gcc-randconfig:
     KBUILD_DEFCONFIG: tiny64_defconfig
     RANDCONFIG: y
     <<: *riscv-fixed-randconfig
+
+# macOS build jobs
+.macos-26:
+  <<: *build
+  tags:
+    - saas-macos-medium-m1
+  image: macos-26-xcode-26
+  variables:
+    HOMEBREW_NO_AUTO_UPDATE: 1
+    HOSTCC: clang
+    HYPERVISOR_ONLY: y
+    <<: *gcc
+  script:
+    - brew install ${CROSS_COMPILE}gcc ${CROSS_COMPILE}binutils
+    - alias nproc="sysctl -n hw.ncpu"
+    - ./automation/scripts/build 2>&1 | tee build.log
+
+macos-26-x86_64:
+  extends:
+    - .macos-26
+  variables:
+    XEN_TARGET_ARCH: x86_64
+    CROSS_COMPILE: x86_64-elf-
+
+macos-26-arm64:
+  extends:
+    - .macos-26
+  variables:
+    XEN_TARGET_ARCH: arm64
+    CROSS_COMPILE: aarch64-elf-
Signature · 1 line
2.53.0
#1 lore raw
Quoted 11 lines · Roger Pau Monne

With the imminent decommission of CirrusCI we will lose the limited macOS build testing done there. Introduce two Gitlab macOS build jobs that reproduce the ones present on CirrusCI.

According to the "Community programs" Gitlab documentation [0] we get 50,000 compute minutes per month. The arm64 job takes ~1m 15s, and the x86_64 one ~2m. I think it's likely enough given the amount of minutes we have available. We might need to reconsider if we add more tasks that consume compute minutes.

[0] https://docs.gitlab.com/subscriptions/community_programs/#gitlab-for-open-source

Ping?

Thanks, Roger.

Acked-by on v1 1/1
#2 lore raw
In reply to Roger Pau Monne
Quoted 10 lines · Roger Pau Monne

With the imminent decommission of CirrusCI we will lose the limited macOS build testing done there. Introduce two Gitlab macOS build jobs that reproduce the ones present on CirrusCI.

According to the "Community programs" Gitlab documentation [0] we get 50,000 compute minutes per month. The arm64 job takes ~1m 15s, and the x86_64 one ~2m. I think it's likely enough given the amount of minutes we have available. We might need to reconsider if we add more tasks that consume compute minutes.

Quoted 3 lines

[0] https://docs.gitlab.com/subscriptions/community_programs/#gitlab-for-open-source