如何更改 iPhone 部署目标

How to change iPhone deployment target

我今天也用 Xcode 更新了 flutter,当我尝试 运行 我的应用程序 IOS

时出现错误

warning: The iOS Simulator deployment target 'IPHONEOS_DEPLOYMENT_TARGET' is set to 7.0, but the range of supported deployment target versions is 8.0 to 13.4.99. (in target 'gRPC-C++-gRPCCertificates-Cpp' from project 'Pods')

...

当我从 Xcode 转到 运行ner 时,我只能将其更改为最小版本 8

Flutter 医生结果

[✓] Flutter (Channel stable, v1.12.13+hotfix.9-pre.2, on Mac OS X 10.15.4 19E266, locale en-GB) • Flutter version 1.12.13+hotfix.9-pre.2 at /Users/peter/development/tools/flutter • Framework revision f139b11009 (3 days ago), 2020-03-30 13:57:30 -0700 • Engine revision af51afceb8 • Dart version 2.7.2

[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.2) • Android SDK at /Users/peter/Library/Android/sdk • Android NDK location not configured (optional; useful for native profiling support) • Platform android-29, build-tools 29.0.2 • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java • Java version OpenJDK Runtime Environment (build 1.8.0_212-release-1586-b4-5784211) • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 11.4) • Xcode at /Applications/Xcode.app/Contents/Developer • Xcode 11.4, Build version 11E146 • CocoaPods version 1.8.4

[✓] Android Studio (version 3.6) • Android Studio at /Applications/Android Studio.app/Contents • Flutter plugin version 44.0.2 • Dart plugin version 192.7761 • Java version OpenJDK Runtime Environment (build 1.8.0_212-release-1586-b4-5784211)

[✓] IntelliJ IDEA Community Edition (version 2019.3) • IntelliJ at /Applications/IntelliJ IDEA CE.app • Flutter plugin version 42.1.4 • Dart plugin version 193.5731

[✓] Connected device (1 available) • iPhone 11 Pro Max • 269B6B4A-E1E4-4461-B0F8-02DA3D21E477 • ios • com.apple.CoreSimulator.SimRuntime.iOS-13-4 (simulator)

那么如何将 iPhone 部署目标更改为更高版本 颤动?

更新

更新 android 工作室消除了错误。

如果您在 Xcode 项目中更改了 Deployment Target,请在您的 Flutter 应用中打开 ios/Flutter/AppframeworkInfo.plist 并更新 MinimumOSVersion 值以匹配。

MinimumOSVersion 部分将 OSVersion 更改为 8.0 以上(最好尝试相同的项目版本)。