在Codemagic上为iOS构建flutter应用程序时出错-在目标`Runner`上自动为平台`iOS`分配了版本`8.0`

时间:2020-06-10 11:53:41

标签: ios flutter codemagic

当尝试构建Flutter应用时,codemagic在下面显示错误。

Error output from CocoaPods:
↳

    [!] Automatically assigning platform `iOS` with version `8.0` on target `Runner` because no platform was specified. Please specify a platform for this target in your Podfile. See `https://guides.cocoapods.org/syntax/podfile.html#platform`.

Error running pod install


Build failed :|
Failed to build for iOS

该应用可以在android上正常构建

我还注意到以下错误:

   [!] CocoaPods could not find compatible versions for pod "firebase_ml_vision":
      In Podfile:
        firebase_ml_vision (from `.symlinks/plugins/firebase_ml_vision/ios`)

    Specs satisfying the `firebase_ml_vision (from `.symlinks/plugins/firebase_ml_vision/ios`)` dependency were found, but they required a higher minimum deployment target.

1 个答案:

答案 0 :(得分:1)

您需要按照插件文档中的说明在Podfile中增加部署目标

版本0.7.0+使用最新的ML Kit for Firebase版本, 要求的最低部署目标为9.0。您可以添加行 平台:ios,iOS项目Podfile中的“ 9.0”。

导航到ios/Podfile(而不是Podfile.lock),并通过删除#取消注释第二行,然后尝试再次构建。