fix: build on current toolchains (iOS 27, Flutter 3.47) - #34
Merged
Conversation
iOS 27 terminates apps that have not adopted the UIScene lifecycle, and Flutter 3.47 enforces AGP/Kotlin minimums this project was below, so the Android build failed outright. - iOS: adopt UIScene (UIApplicationSceneManifest + FlutterImplicitEngineDelegate) - iOS/macOS: drop use_modular_headers!, raise platforms to 15.0 / 12.0 - Android: AGP 8.10.1 -> 8.11.1, Kotlin 2.1.0 -> 2.2.20, Gradle 8.11.1 -> 8.14 (AGP 8.11 requires Gradle >= 8.13) - Android: use flutter.ndkVersion, Java 17 Verified: Android APK, iOS simulator and macOS all build; app launches on the iOS 27 simulator.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
iOS 27 terminates apps that haven't adopted the UIScene lifecycle, and Flutter 3.47 enforces AGP/Kotlin minimums this project was below — so the Android build failed outright and the iOS app wouldn't launch.
Changes
iOS — UIScene
UIApplicationSceneManifestinInfo.plist, using the stockFlutterSceneDelegate(no custom scene delegate needed)AppDelegateconforms toFlutterImplicitEngineDelegate, registering plugins indidInitializeImplicitFlutterEngine. Under UIScene the app delegate'swindowis nil, so registration can't stay indidFinishLaunchingWithOptions.Flutter's auto-migrator doesn't fire here — the
AppDelegatedoesn't match any of its templates.Android — Flutter 3.47 minimums
8.10.1→8.11.1, Kotlin2.1.0→2.2.208.11.1→8.14(AGP 8.11 requires ≥ 8.13)ndkVersion→flutter.ndkVersion, Java target → 17iOS/macOS — Podfiles
use_modular_headers!(not in any Flutter template)15.0, macOS12.0Verified
Draft — worth a look at whether the platform floors match what this starter wants to support.