Skip to content

Fix Xcode 27 lipo verification failure for Darwin frameworks - #188625

Merged
auto-submit[bot] merged 1 commit into
flutter:masterfrom
okorohelijah:fix_188346
Jun 26, 2026
Merged

auto-submit[bot] merged 1 commit into
flutter:masterfrom
okorohelijah:fix_188346

Conversation

@okorohelijah

@okorohelijah okorohelijah commented Jun 26, 2026 •

Copy link
Copy Markdown
Contributor

This PR fixes a blocking build failure encountered when building iOS and macOS apps using the Xcode 27 toolchain.

List which issues are fixed by this PR. You must list at least one issue. An issue is not required if the PR fixes something trivial like a typo.

Fixes #188346, #188461

If you had to change anything in the flutter/tests repo, include a link to the migration guide as per the breaking change policy.

Pre-launch Checklist

If you need help, consider asking for advice on the #hackers-new channel on Discord.

If this change needs to override an active code freeze, provide a comment explaining why. The code freeze workflow can be overridden by code reviewers. See pinned issues for any active code freezes with guidance.

Note: The Flutter team is currently trialing the use of Gemini Code Assist for GitHub. Comments from the gemini-code-assist bot should not be taken as authoritative feedback from the Flutter team. If you find its comments useful you can update your code accordingly, but if you are unsure or disagree with the feedback, please feel free to wait for a Flutter team member's review for guidance on which automated comments should be addressed.

@github-actions github-actions Bot added tool Affects the "flutter" command-line tool. See also t: labels. team-ios Owned by iOS platform team team-macos Owned by the macOS platform team labels Jun 26, 2026
@okorohelijah okorohelijah added the CICD Run CI/CD label Jun 26, 2026
@okorohelijah
okorohelijah marked this pull request as ready for review June 26, 2026 12:46
@okorohelijah
okorohelijah requested review from a team as code owners June 26, 2026 12:46
@okorohelijah
okorohelijah requested a review from vashworth June 26, 2026 12:46

@gemini-code-assist gemini-code-assist Bot 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.

Code Review

This pull request updates the Darwin build target to verify each architecture individually using lipo -verify_arch in a loop, rather than verifying all architectures in a single command. The corresponding unit tests are updated to match this new behavior. The reviewer suggests improving the error message thrown during verification failure to specify the exact architecture that failed, aligning with the style guide's principle that error messages should be useful.

Comment thread packages/flutter_tools/lib/src/build_system/targets/darwin.dart
@okorohelijah

Copy link
Copy Markdown
Contributor Author

I think the issue might be a regression from apple and may be fixed in an official release because based on the official documentation when i ran man lipo this was what i found:

 -verify_arch arch_type ...
      Take one input file and verify the specified arch_types are present in the file.  If so then exit with a status of 0 else exit with a status of
      1. Because more than one arch_type can be verified at once, all of the input files must appear before the -verify_arch flag on the command-line.

@vashworth

Copy link
Copy Markdown
Contributor

@okorohelijah If you haven't already, please make sure to verify locally that it fixes the issues with Xcode 27. You'll need to download it from go/xcode if you haven't already.

@okorohelijah

Copy link
Copy Markdown
Contributor Author

yup, i already verified that it works

@okorohelijah okorohelijah added the cp: stable cherry pick this pull request to stable release candidate branch label Jul 21, 2026
marcobazzani pushed a commit to marcobazzani/FinanceCopilot that referenced this pull request Sep 16, 2026
Xcode 27 raises the minimum macOS deployment target to 12.0 and changes
lipo -verify_arch to one architecture per call; Flutter 3.41.6 fails on
both. Move to Flutter 3.47.4 (contains flutter/flutter#188625) and align
the project:

- .flutter-version + CI: 3.41.6 -> 3.47.4
- macOS minimum 10.15 -> 12.0 (Podfile, Runner.xcodeproj), matching
  flutter/flutter#187762
- pdfrx ^2.4.1 -> ^2.6.1: pdfrx_engine 0.4.2 does not compile on Dart
  3.13; drop the now-inert dismissPdfiumWasmWarnings flag
- ReorderableListView.onReorder -> onReorderItem (deprecated in 3.47;
  the callback already delivers the post-removal index)
- analysis_options: declare the platform-directory excludes that the
  3.47 AnalysisOptionsMigration otherwise rewrites on every pub get
- Swift Package Manager scaffolding generated by 3.47 (Package.resolved,
  scheme, plugin registrant, Podfile.lock)
@mrtnrst

mrtnrst commented Sep 21, 2026

Copy link
Copy Markdown

For anyone else looking at this issue and can't upgrade to 3.47.x yet, this was shipped as a patch in 3.44.8

#189792
https://github.com/flutter/flutter/blob/3.44.9/CHANGELOG.md?plain=1#L38-L40

MylioScott pushed a commit to mylollc/flutter that referenced this pull request Sep 29, 2026
…#188625)

This PR fixes a blocking build failure encountered when building iOS and
macOS apps using the Xcode 27 toolchain.

*List which issues are fixed by this PR. You must list at least one
issue. An issue is not required if the PR fixes something trivial like a
typo.*

Fixes flutter#188346, flutter#188461

*If you had to change anything in the [flutter/tests] repo, include a
link to the migration guide as per the [breaking change policy].*

## Pre-launch Checklist

- [x] I read the [Contributor Guide] and followed the process outlined
there for submitting PRs.
- [x] I read the [AI contribution guidelines] and understand my
responsibilities, or I am not using AI tools.
- [x] I read the [Tree Hygiene] wiki page, which explains my
responsibilities.
- [x] I read and followed the [Flutter Style Guide], including [Features
we expect every widget to implement].
- [x] I signed the [CLA].
- [x] I listed at least one issue that this PR fixes in the description
above.
- [ ] I updated/added relevant documentation (doc comments with `///`).
- [ ] I added new tests to check the change I am making, or this PR is
[test-exempt].
- [ ] I followed the [breaking change policy] and added [Data Driven
Fixes] where supported.
- [x] All existing and new tests are passing.

If you need help, consider asking for advice on the #hackers-new channel
on [Discord].

If this change needs to override an active code freeze, provide a
comment explaining why. The code freeze workflow can be overridden by
code reviewers. See pinned issues for any active code freezes with
guidance.

**Note**: The Flutter team is currently trialing the use of [Gemini Code
Assist for
GitHub](https://developers.google.com/gemini-code-assist/docs/review-github-code).
Comments from the `gemini-code-assist` bot should not be taken as
authoritative feedback from the Flutter team. If you find its comments
useful you can update your code accordingly, but if you are unsure or
disagree with the feedback, please feel free to wait for a Flutter team
member's review for guidance on which automated comments should be
addressed.

<!-- Links -->
[Contributor Guide]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#overview
[AI contribution guidelines]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#ai-contribution-guidelines
[Tree Hygiene]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md
[test-exempt]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#tests
[Flutter Style Guide]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Style-guide-for-Flutter-repo.md
[Features we expect every widget to implement]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Style-guide-for-Flutter-repo.md#features-we-expect-every-widget-to-implement
[CLA]: https://cla.developers.google.com/
[flutter/tests]: https://github.com/flutter/tests
[breaking change policy]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#handling-breaking-changes
[Discord]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Chat.md
[Data Driven Fixes]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Data-driven-Fixes.md
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CICD Run CI/CD cp: stable cherry pick this pull request to stable release candidate branch team-ios Owned by iOS platform team team-macos Owned by the macOS platform team tool Affects the "flutter" command-line tool. See also t: labels.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

release_unpack_macos fails on Xcode 27

3 participants