Skip to content

deps: support Xcode 27 and iOS 27 - #1181

Merged
anhappdev merged 4 commits into
masterfrom
xcode27-ios27-support
Sep 29, 2026
Merged

anhappdev merged 4 commits into
masterfrom
xcode27-ios27-support

Conversation

@anhappdev

@anhappdev anhappdev commented Sep 22, 2026 •

Copy link
Copy Markdown
Collaborator

Xcode 27 and iOS 27 support, plus the CI changes that would have caught the breakage before master. The first two commits are cherry-picked from #1175; the rest come from reading the Xcode Cloud logs for builds 272 and 273.

  • Xcode 27 build break (eea9fe96) — swiftc refuses coreml_util with emitting module interface files requires '-language-mode'; Xcode 27 no longer defaults the language mode. The CoreML swift_library now passes -swift-version 6. The source is mode-agnostic; 6 is what Xcode 27 would pick.
  • iOS 27 launch trap (fb2444c5) — UIKit traps when an app has not adopted the UIScene lifecycle. Both Info plists declare UIApplicationSceneManifest naming FlutterSceneDelegate, and plugin registration moves to FlutterImplicitEngineDelegate, since the implicit engine does not exist during didFinishLaunchingWithOptions. Both protocols are in the pinned Flutter 3.44.4.
  • Intel/Rosetta CI machine (9985b710) — build 273 landed on macOS 26.5.1 where brew resolves to the x86_64 install at /usr/local under Rosetta 2. No Intel bottles since September 2026, so protobuf built from source and died on clang: error: unsupported argument 'westmere' to option '-march='. ci_post_clone.sh now prefers /opt/homebrew and logs the resolved brew.
  • Xcode 27 CI coverage (f58e0326) — Xcode Cloud archives with Xcode 27 and runs only on master, so this class of break is invisible until after merge. The two existing legs move from macos-15 to macos-26 (newest Xcode 26.6 rather than 26.3), and a new apple-xcode27 leg builds on the xcode-27 image — Xcode 27.0 build 27A266a, the same build Xcode Cloud uses.

Notes:

  • The new leg builds and unit-tests only; the test package and BrowserStack stay on the GA image. xcode-27 is still a GitHub preview with limited capacity, so the leg is continue-on-error — a queueing hiccup must not block the BrowserStack jobs that depend on this one. Drop that when the image reaches GA.
  • Cache keys, the test package and the artifact are now keyed on a new label rather than the backend, since two legs build apple. Existing check names are unchanged.
  • Pinning the Xcode Cloud workflow to the macOS 27 image is being done separately in App Store Connect.
  • The first two issues were reported by @freedomtan.

Xcode 27 stopped defaulting the Swift language mode, so `swiftc` refuses
to compile `coreml_util.swift` under `make WITH_APPLE=1` without one.
The source does not depend on the mode; 6 is what Xcode 27 would choose.

Reported by @freedomtan against Xcode 27.0 on macOS 27.0.

(cherry picked from commit 056213c)
On iOS 27 UIKitCore raises a runtime issue when an app has not adopted the
scene-based life cycle, which lands as a debugger trap (brk #0) and stops
the app under LLDB.

Declare a UIApplicationSceneManifest naming FlutterSceneDelegate in both
Info plists, and move plugin registration off didFinishLaunchingWithOptions.
Under the scene lifecycle the implicit engine is created after that call, so
registering there would run against an engine that does not exist yet;
FlutterImplicitEngineDelegate hands us the engine once it does.

Both protocols are present in the Flutter pinned by CI (3.44.4).

Reported by @freedomtan against iOS 27.

(cherry picked from commit f4e8400)
@anhappdev
anhappdev requested a review from a team as a code owner September 22, 2026 07:02
@github-actions

Copy link
Copy Markdown

MLCommons CLA bot All contributors have signed the MLCommons CLA ✍️ ✅

Xcode Cloud does not always allocate the same machine. Build 272 ran on
macOS 27.0 arm64 with brew at /opt/homebrew; build 273, an hour later on
the same commit, ran on macOS 26.5.1 with brew resolved to the x86_64
install at /usr/local under Rosetta 2.

Homebrew stopped building Intel bottles in September 2026. On that second
machine bazelisk still had a bottle, but protobuf 36.2 had none and fell
back to a source build that failed:

  clang: error: unsupported argument 'westmere' to option '-march='

Rosetta reports a westmere CPU that the native clang will not accept, so
every formula without an Intel bottle will fail there from now on.

Prefer /opt/homebrew when it exists, and log the resolved brew so the
machine's architecture is visible in the log rather than inferred from a
bottle name. This is a no-op on the arm64 image, which already uses it.
Xcode Cloud archives with Xcode 27 and only runs on master, so an Xcode 27
break is invisible until after merge. That is how swiftc refusing
coreml_util without -swift-version reached master.

- Move the two existing legs from macos-15 to macos-26. Newest Xcode there
  is 26.6 rather than 26.3, matching Xcode Cloud's other machine.
- Add an apple-xcode27 leg on the xcode-27 image: macOS 27, Xcode 27.0
  build 27A266a, the same build Xcode Cloud uses.
- Select the newest Xcode 26.x or 27.x instead of requiring 26.x, which
  would fail on xcode-27; that image ships no Xcode 26.
- Key the pods and bazel disk caches, the test package and the artifact on
  a new `label` rather than the backend, since two legs now build `apple`.
- The new leg builds and unit-tests only. The test package and BrowserStack
  stay on the GA image.

xcode-27 is still a GitHub preview with limited capacity, so the leg is
continue-on-error: a queueing hiccup there must not block the BrowserStack
jobs that need this one. Drop that once the image reaches GA.
@sonarqubecloud

Copy link
Copy Markdown

@anhappdev anhappdev changed the title fix: support Xcode 27 and iOS 27 choẻ: support Xcode 27 and iOS 27 Sep 25, 2026
@anhappdev anhappdev changed the title choẻ: support Xcode 27 and iOS 27 deps: support Xcode 27 and iOS 27 Sep 25, 2026

@freedomtan freedomtan left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@anhappdev
anhappdev merged commit fa359f6 into master Sep 29, 2026
50 of 56 checks passed
@anhappdev
anhappdev deleted the xcode27-ios27-support branch September 29, 2026 05:40
@github-actions github-actions Bot locked and limited conversation to collaborators Sep 29, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants