简体   繁体   English

构建 Flutter iOS 应用时出错 - Firebase

[英]Error building Flutter iOS app - Firebase

My app is not building for the iOS simulator.我的应用程序不是为 iOS 模拟器构建的。

I've tried a clean, looks like it's a Firebase issue.我试过一个干净的,看起来是一个 Firebase 问题。

I'm using these versions:我正在使用这些版本:

dependencies: flutter: sdk: flutter firebase_core: ^0.5.0 cloud_firestore: ^0.14.0+2 firebase_auth: ^0.18.0+1依赖项:flutter:sdk:flutter firebase_core:^0.5.0 cloud_firestore:^0.14.0+2 firebase_auth:^0.18.0+1

In file included from /Users/ramshaw/.pub-cache/hosted/pub.dartlang.org/firebase_core-0.5.0/ios/Classes/FLTFirebasePluginRegistry.m:5:
In file included from /Users/ramshaw/.pub-cache/hosted/pub.dartlang.org/firebase_core-0.5.0/ios/Classes/FLTFirebasePluginRegistry.h:6:
/Users/ramshaw/.pub-cache/hosted/pub.dartlang.org/firebase_core-0.5.0/ios/Classes/FLTFirebasePlugin.h:123:4: error: expected a type
+ (FlutterError *_Nonnull)createFlutterErrorFromCode:(NSString *_Nonnull)code
   ^
1 error generated.
note: Using new build system
note: Building targets in parallel
note: Planning build
note: Constructing build description

Could not build the application for the simulator.无法为模拟器构建应用程序。 Error launching application on iPhone 11.在 iPhone 11 上启动应用程序时出错。

Fixed.固定的。

  1. Created a new Flutter project创建了一个新的 Flutter 项目
  2. Copied over the pub spec.yaml file, checked the app was building.复制 pub spec.yaml 文件,检查正在构建的应用程序。
  3. Repeated step 2 for the rest of my lib files, one file at a time.对其余的 lib 文件重复第 2 步,一次一个文件。

Why one file at a time?为什么一次一个文件?

'cause if I replaced the folder, it did not build.因为如果我替换了文件夹,它就没有建立。

I'm happy my app is building again but not sure why and that doesn't make me happy.我很高兴我的应用程序再次构建,但不知道为什么,这并没有让我高兴。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 为iOS 8构建基于Firebase的应用程序时链接错误 - Linking Error in building Firebase powered app for iOS 8 Firebase Crashlytics 安装错误 Flutter - IOS 应用程序 - Error on Firebase Crashlytics installation for Flutter - IOS app 从flutter构建iOS应用程序时出错 - Getting error while building iOS app from flutter 使用 Flutter 构建 iOS 应用程序时出错 - 缺少 DVTPlugInCompatibilityUUID 插件 - Error building iOS app with Flutter - Missing DVTPlugInCompatibilityUUID plugin 在 Flutter 2.0.4 上构建 iOS 应用程序错误:找不到“Flutter/Flutter.h”文件 - Building iOS app on Flutter 2.0.4 error: 'Flutter/Flutter.h' file not found 使用 firebase-auth 时在 ios 上构建应用程序会导致颤振问题 - Building app on ios when using firebase-auth causes a problem with flutter Flutter 应用程序未在 IOS 仿真器上运行或构建 - Flutter app not running or building on IOS Emulator 构建 iOS 应用程序以在 Flutter 上发布的问题 - Problem in Building iOS app for release on flutter 在codemagic上为ios构建flutter应用程序时出错-在目标“Runner”上自动分配版本为“8.0”的平台“iOS” - Error while building flutter app for ios on codemagic - Automatically assigning platform `iOS` with version `8.0` on target `Runner` 为iOS生成Sencha App错误 - Building Sencha App for iOS error
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM