VerteDinde

#48467: build: handle Metal toolchain being unbundled from Xcode 26

Merged
Created: Oct 4, 2025, 11:58:16 PM
Merged: Oct 6, 2025, 9:17:47 AM
4 comments
Target: main

mac: handle Metal toolchain being unbundled from Xcode 26

The Metal toolchain was formerly part of Xcode, but in Xcode 26, it has
been unbundled and is now a separate install. Attempting to use the
Metal toolchain without installing it results in a build error, such as:

error: error: cannot execute tool 'metal' due to missing Metal
Toolchain; use: xcodebuild -downloadComponent MetalToolchain

By running the suggested command, the Metal toolchain can be installed,
but the existing angle build does not know how to find it correctly.

For system Xcode installations, tools from the Metal toolchain (metal
and metallib) can be run via xcrun. This construct should work
equally well for older Xcode versions, for situations where it’s still
in use.

For the hermetic toolchain, we’ll continue splicing the Metal toolchain
into the location it had previously been avialable (see
https://chromium-review.googlesource.com/c/6950738), although this is
subject to change in the future.

Bug: chromium:423933062, chromium:445400016
Change-Id: I139eca51938f7cecfec9b90fd488947160ef4ec9
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/6955000
Auto-Submit: Mark Mentovai mark@chromium.org
Commit-Queue: Mark Mentovai mark@chromium.org
Reviewed-by: Geoff Lang geofflang@chromium.org

Notes: Fixed a development issue where the metal toolchain could not be found when building on macOS 26.

Backports

37-x-y
In-flight
PR Number
#48471
Waiting to be merged
38-x-y
In-flight
PR Number
#48473
Waiting to be merged
39-x-y
Merged
PR Number
#48472
Merged At
Oct 6, 2025, 4:32:29 PM
Released In
v39.0.0-beta.1
Release Date
Oct 6, 2025, 4:34:18 PM

Semver Impact

Major
Breaking changes
Minor
New features
Patch
Bug fixes
None
Docs, tests, etc.

Semantic Versioning helps users understand the impact of updates:

  • Major (X.y.z): Breaking changes that may require code modifications
  • Minor (x.Y.z): New features that maintain backward compatibility
  • Patch (x.y.Z): Bug fixes that don't change the API
  • None: Changes that don't affect using facing parts of Electron