Flutter-iOS Simulator部署目标"IPHONEOS_DEPLOYMENT_TARGET"设置为7.0&&找不到构建输入文件GoogleService-Info.plist [英] Flutter - The iOS Simulator deployment target 'IPHONEOS_DEPLOYMENT_TARGET' is set to 7.0 && Build input file cannot be found GoogleService-Info.plist

查看:141
本文介绍了Flutter-iOS Simulator部署目标"IPHONEOS_DEPLOYMENT_TARGET"设置为7.0&&找不到构建输入文件GoogleService-Info.plist的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我无法在iOS模拟器上构建Flutter应用.我一遍又一遍地收到此错误.我的扑打医生很干净.

I cannot build a Flutter app on iOS simulator. I am getting this error over and over. My flutter-doctor is clean.

 Launching lib/main.dart on iPhone SE (2nd generation) in debug mode...
    Xcode build done.                                           26,7s
    Failed to build iOS app
    Error output from Xcode build:
    ↳
        ** BUILD FAILED **
    Xcode's output:
    ↳
        error: Build input file cannot be found: '/Users/User/Downloads/GoogleService-Info.plist' (in target 'Runner' from project 'Runner')
        note: Using new build system
        note: Building targets in parallel
        note: Planning build
        note: Constructing build description
        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 'AppAuth' from project 'Pods')
        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 'GTMAppAuth' from project 'Pods')
        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-Core' from project 'Pods')
        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 'BoringSSL-GRPC' from project 'Pods')
        warning: The iOS Simulator deployment target 'IPHONEOS_DEPLOYMENT_TARGET' is set to 5.0, but the range of supported deployment target versions is 8.0 to 13.4.99. (in target 'leveldb-library' from project 'Pods')
        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')
        warning: The iOS Simulator deployment target 'IPHONEOS_DEPLOYMENT_TARGET' is set to 4.3, but the range of supported deployment target versions is 8.0 to 13.4.99. (in target 'nanopb' from project 'Pods')
        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 'GTMSessionFetcher' from project 'Pods')
        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++' from project 'Pods')
        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 'abseil' from project 'Pods')
    Could not build the application for the simulator.
    Error launching application on iPhone SE (2nd generation).
    Exited (sigterm)

推荐答案

要消除此警告,请执行以下操作:

To get rid of this warning:

    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 'AppAuth' from project 'Pods')
    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 'GTMAppAuth' from project 'Pods')
    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-Core' from project 'Pods')
    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 'BoringSSL-GRPC' from project 'Pods')
    warning: The iOS Simulator deployment target 'IPHONEOS_DEPLOYMENT_TARGET' is set to 5.0, but the range of supported deployment target versions is 8.0 to 13.4.99. (in target 'leveldb-library' from project 'Pods')
    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')
    warning: The iOS Simulator deployment target 'IPHONEOS_DEPLOYMENT_TARGET' is set to 4.3, but the range of supported deployment target versions is 8.0 to 13.4.99. (in target 'nanopb' from project 'Pods')
    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 'GTMSessionFetcher' from project 'Pods')
    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++' from project 'Pods')
    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 'abseil' from project 'Pods')

确保您的 Podfile 包含此行

config.build_settings ['IPHONEOS_DEPLOYMENT_TARGET'] ='9.0'

post_install do |installer|
  installer.pods_project.targets.each do |target|
    target.build_configurations.each do |config|
      config.build_settings['ENABLE_BITCODE'] = 'NO'
        config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '9.0'
    end
  end
end

要使应用成功构建并摆脱:

To make the app build successfully and get rid of:

error: Build input file cannot be found: '/Users/User/Downloads/GoogleService-Info.plist' (in target 'Runner' from project 'Runner')

通过Xcode (GoogleService-Info.plist文件)删除并再次添加.

remove and add again through Xcode, the GoogleService-Info.plist file.

这篇关于Flutter-iOS Simulator部署目标"IPHONEOS_DEPLOYMENT_TARGET"设置为7.0&&找不到构建输入文件GoogleService-Info.plist的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆