[PR #3870] [CLOSED] [Other] CI: build the Metal engine on macos-26 (the Metal 4 API needs the macOS 26 SDK) #4809

Closed
opened 2026-11-07 15:39:11 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Niko1221/Strata/pull/3870
Author: @stuchapin909
Created: 10/23/2026
Status: ❌ Closed

Base: main ← Head: ci/metal-macos-26


📝 Commits (1)

  • d1ce044 CI: build the Metal engine on macos-26 (the Metal 4 API needs the macOS 26 SDK)

📊 Changes

1 file changed (+3 additions, -1 deletions)

View changed files

📝 .github/workflows/metal-build.yml (+3 -1)

📄 Description

Problem and result

The metal-link job (.github/workflows/metal-build.yml) fails on every pull request that touches src/, include/ or metal/, before it reaches the PR's own files:

metal/src/mtl_rt.mm:69:70: error: use of undeclared identifier 'MTLGPUFamilyMetal4'; did you mean 'MTLGPUFamilyMetal3'?
metal/src/mtl_rt.mm:92:11: error: property 'mathMode' not found on object of type 'MTLCompileOptions *'
metal/src/mtl_rt.mm:92:34: error: use of undeclared identifier 'MTLMathModeFast'
metal/src/mtl_rt.mm:92:52: error: use of undeclared identifier 'MTLMathModeSafe'

The job runs on macos-14 (macOS 14 SDK). mtl_rt.mm uses MTLGPUFamilyMetal4 (macOS 26 SDK) and MTLCompileOptions.mathMode (macOS 15 SDK) behind @available, which is a run-time check; the names must still exist in the SDK at compile time. With runs-on: macos-26 the job builds and links again.

none. The same failure shows on #3869 and on the other PRs opened today (decode-timing, ram-adapt-stage, window-trace, the GP100 series, f-mac-update-model-silent).

Approach

One line: runs-on: macos-14 -> macos-26, plus a two-line comment saying why. It matches the metal-cpp_26.zip the job already downloads. The engine source is unchanged. Guarding the two calls with SDK-version #ifs would also fix builds on older Xcode, but it touches engine code I cannot test on a Mac, so I left that out.

Validation

Passed:

Failed:

  • none observed

Not run:

  • Running the built engine on a Mac (the job only builds and links; I have no Mac).

Limits

Building from source on a Mac with an SDK older than macOS 26 still fails the same way; this only fixes CI.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/Niko1221/Strata/pull/3870 **Author:** [@stuchapin909](https://github.com/stuchapin909) **Created:** 10/23/2026 **Status:** ❌ Closed **Base:** `main` ← **Head:** `ci/metal-macos-26` --- ### 📝 Commits (1) - [`d1ce044`](https://github.com/Niko1221/Strata/commit/d1ce044b280ae8822e217226854fc6c88093c28f) CI: build the Metal engine on macos-26 (the Metal 4 API needs the macOS 26 SDK) ### 📊 Changes **1 file changed** (+3 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `.github/workflows/metal-build.yml` (+3 -1) </details> ### 📄 Description ## Problem and result The `metal-link` job (`.github/workflows/metal-build.yml`) fails on every pull request that touches `src/`, `include/` or `metal/`, before it reaches the PR's own files: ``` metal/src/mtl_rt.mm:69:70: error: use of undeclared identifier 'MTLGPUFamilyMetal4'; did you mean 'MTLGPUFamilyMetal3'? metal/src/mtl_rt.mm:92:11: error: property 'mathMode' not found on object of type 'MTLCompileOptions *' metal/src/mtl_rt.mm:92:34: error: use of undeclared identifier 'MTLMathModeFast' metal/src/mtl_rt.mm:92:52: error: use of undeclared identifier 'MTLMathModeSafe' ``` The job runs on `macos-14` (macOS 14 SDK). `mtl_rt.mm` uses `MTLGPUFamilyMetal4` (macOS 26 SDK) and `MTLCompileOptions.mathMode` (macOS 15 SDK) behind `@available`, which is a run-time check; the names must still exist in the SDK at compile time. With `runs-on: macos-26` the job builds and links again. ## Related discussion none. The same failure shows on #3869 and on the other PRs opened today (decode-timing, ram-adapt-stage, window-trace, the GP100 series, f-mac-update-model-silent). ## Approach One line: `runs-on: macos-14` -> `macos-26`, plus a two-line comment saying why. It matches the `metal-cpp_26.zip` the job already downloads. The engine source is unchanged. Guarding the two calls with SDK-version `#if`s would also fix builds on older Xcode, but it touches engine code I cannot test on a Mac, so I left that out. ## Validation **Passed:** - `metal-build.yml` via `workflow_dispatch` on this branch (`d1ce044b`, on main `7ddc17a3`) in my fork: every step passed, including "Build and link the engine": https://github.com/stuchapin909/Strata/actions/runs/39992739258 **Failed:** - none observed **Not run:** - Running the built engine on a Mac (the job only builds and links; I have no Mac). ## Limits Building from source on a Mac with an SDK older than macOS 26 still fails the same way; this only fixes CI. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-07 15:39:11 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Niko1221/Strata#4809
No description provided.