Flutter cloud_firestore包可在更新后阻止iOS构建

时间:2018-04-01 21:42:34

标签: xcode firebase dart google-cloud-firestore flutter

在我使用flutter upgrade并安装了最新版本的flutter后,我遇到了这个问题,我的项目无法使用firestore插件进行编译。如果我删除它,项目将按预期工作。

以下是flutter build ios

的终端输出
Running pod install...                                      26.1s
Running Xcode clean...                                       2.8s
Starting Xcode build...                                          
Xcode build done                                            74.5s
Failed to build iOS app
Error output from Xcode build:
↳
    ** BUILD FAILED **

Xcode's output:
↳
       ....
/Users/loaner/Documents/IntelliJ_Projects/augmentalflutter/ios/Pods/Headers/Private/Protobuf/GPBProtocolBuffers.h:64:10: warning: non-portable path to file '<protobuf/Wrappers.pbobjc.h>'; specified path differs in case from file name on disk [-Wnonportable-include-path]
         #import <Protobuf/Wrappers.pbobjc.h>
                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
                 <protobuf/Wrappers.pbobjc.h>
        13 warnings generated.
        === BUILD TARGET cloud_firestore OF PROJECT Pods WITH CONFIGURATION Release ===
        In file included from /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:5:
        In file included from .symlinks/plugins/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.h:5:
        In file included from /Users/loaner/Documents/IntelliJ_Projects/augmentalflutter/ios/Pods/Headers/Public/Flutter/Flutter/Flutter.h:37:
        In file included from Headers/Public/Flutter/Flutter/FlutterAppDelegate.h:11:
        Headers/Public/Flutter/Flutter/FlutterPlugin.h:80:42: warning: 'UIUserNotificationSettings' is partial: introduced in iOS 8.0 - Use UserNotifications Framework's UNNotificationSettings [-Wunguarded-availability]
            didRegisterUserNotificationSettings:(UIUserNotificationSettings*)notificationSettings;
                                                 ^
        In module 'UIKit' imported from /Users/loaner/Documents/IntelliJ_Projects/augmentalflutter/ios/Pods/Target Support Files/cloud_firestore/cloud_firestore-prefix.pch:2:
        /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS11.2.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIUserNotificationSettings.h:43:12: note: 'UIUserNotificationSettings' has been explicitly marked partial here
        @interface UIUserNotificationSettings : NSObject
                   ^
        In file included from /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:5:
        In file included from .symlinks/plugins/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.h:5:
        In file included from /Users/loaner/Documents/IntelliJ_Projects/augmentalflutter/ios/Pods/Headers/Public/Flutter/Flutter/Flutter.h:37:
        In file included from Headers/Public/Flutter/Flutter/FlutterAppDelegate.h:11:
        Headers/Public/Flutter/Flutter/FlutterPlugin.h:79:1: note: annotate 'application:didRegisterUserNotificationSettings:' with an availability attribute to silence
        - (void)application:(UIApplication*)application
        ^
        Headers/Public/Flutter/Flutter/FlutterPlugin.h:95:44: warning: 'UIBackgroundFetchResult' is partial: introduced in iOS 7.0 [-Wunguarded-availability]
                  fetchCompletionHandler:(void (^)(UIBackgroundFetchResult result))completionHandler;
                                                   ^
        In module 'UIKit' imported from /Users/loaner/Documents/IntelliJ_Projects/augmentalflutter/ios/Pods/Target Support Files/cloud_firestore/cloud_firestore-prefix.pch:2:
        /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS11.2.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIApplication.h:76:29: note: 'UIBackgroundFetchResult' has been explicitly marked partial here
        typedef NS_ENUM(NSUInteger, UIBackgroundFetchResult) {
                                    ^
        In file included from /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:5:
        In file included from .symlinks/plugins/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.h:5:
        In file included from /Users/loaner/Documents/IntelliJ_Projects/augmentalflutter/ios/Pods/Headers/Public/Flutter/Flutter/Flutter.h:37:
        In file included from Headers/Public/Flutter/Flutter/FlutterAppDelegate.h:11:
        Headers/Public/Flutter/Flutter/FlutterPlugin.h:93:1: note: annotate 'application:didReceiveRemoteNotification:fetchCompletionHandler:' with an availability attribute to silence
        - (BOOL)application:(UIApplication*)application
        ^
        In file included from /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:7:
        In file included from /Users/loaner/Documents/IntelliJ_Projects/augmentalflutter/ios/Pods/Headers/Private/Firebase/Firebase.h:53:
        In file included from /Users/loaner/Documents/IntelliJ_Projects/augmentalflutter/ios/Pods/Headers/Public/FirebaseStorage/FirebaseStorage/FirebaseStorage.h:8:
        Headers/Public/FirebaseStorage/FirebaseStorage/FIRStorageTaskSnapshot.h:53:50: warning: 'NSProgress' is partial: introduced in iOS 7.0 [-Wunguarded-availability]
        @property(readonly, strong, nonatomic, nullable) NSProgress *progress;
                                                         ^
        In module 'Foundation' imported from Headers/Public/Flutter/Flutter/FlutterBinaryMessenger.h:8:
        /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS11.2.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSProgress.h:37:12: note: 'NSProgress' has been explicitly marked partial here
        @interface NSProgress : NSObject {
                   ^
        In file included from /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:7:
        In file included from /Users/loaner/Documents/IntelliJ_Projects/augmentalflutter/ios/Pods/Headers/Private/Firebase/Firebase.h:53:
        In file included from /Users/loaner/Documents/IntelliJ_Projects/augmentalflutter/ios/Pods/Headers/Public/FirebaseStorage/FirebaseStorage/FirebaseStorage.h:8:
        Headers/Public/FirebaseStorage/FirebaseStorage/FIRStorageTaskSnapshot.h:33:12: note: annotate 'FIRStorageTaskSnapshot' with an availability attribute to silence
        @interface FIRStorageTaskSnapshot : NSObject
                   ^
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:106:45: warning: implicit conversion loses integer precision: 'NSUInteger' (aka 'unsigned long') to 'int' [-Wshorten-64-to-32]
              @"oldIndex" : [NSNumber numberWithInt:documentChange.oldIndex],
                            ~                       ^~~~~~~~~~~~~~~~~~~~~~~
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:107:45: warning: implicit conversion loses integer precision: 'NSUInteger' (aka 'unsigned long') to 'int' [-Wshorten-64-to-32]
              @"newIndex" : [NSNumber numberWithInt:documentChange.newIndex],
                            ~                       ^~~~~~~~~~~~~~~~~~~~~~~
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:121:30: error: cannot find interface declaration for 'FlutterStandardWriter', superclass of 'FirestoreWriter'; did you mean 'FlutterStandardBigInteger'?
        @interface FirestoreWriter : FlutterStandardWriter
                                     ^~~~~~~~~~~~~~~~~~~~~
                                     FlutterStandardBigInteger
        In file included from /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:5:
        In file included from .symlinks/plugins/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.h:5:
        In file included from /Users/loaner/Documents/IntelliJ_Projects/augmentalflutter/ios/Pods/Headers/Public/Flutter/Flutter/Flutter.h:37:
        In file included from Headers/Public/Flutter/Flutter/FlutterAppDelegate.h:11:
        In file included from Headers/Public/Flutter/Flutter/FlutterPlugin.h:11:
        In file included from Headers/Public/Flutter/Flutter/FlutterChannels.h:9:
        Headers/Public/Flutter/Flutter/FlutterCodecs.h:268:12: note: 'FlutterStandardBigInteger' declared here
        @interface FlutterStandardBigInteger : NSObject
                   ^
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:121:30: warning: 'FlutterStandardBigInteger' is deprecated: Deprecated on 2018-01-09 to be made unavailable four weeks after the deprecation is available on the flutter/flutter alpha branch. FlutterStandardBigInteger was needed because the Dart 1.0 int type had no size limit. With Dart 2.0, the int type is a fixed-size, 64-bit signed integer. If you need to communicate larger integers, use NSString encoding instead. [-Wdeprecated-declarations]
        @interface FirestoreWriter : FlutterStandardWriter
                                     ^
        In file included from /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:5:
        In file included from .symlinks/plugins/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.h:5:
        In file included from /Users/loaner/Documents/IntelliJ_Projects/augmentalflutter/ios/Pods/Headers/Public/Flutter/Flutter/Flutter.h:37:
        In file included from Headers/Public/Flutter/Flutter/FlutterAppDelegate.h:11:
        In file included from Headers/Public/Flutter/Flutter/FlutterPlugin.h:11:
        In file included from Headers/Public/Flutter/Flutter/FlutterChannels.h:9:
        Headers/Public/Flutter/Flutter/FlutterCodecs.h:261:1: note: 'FlutterStandardBigInteger' has been explicitly marked deprecated here
        FLUTTER_DEPRECATED(
        ^
        In file included from /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:5:
        In file included from .symlinks/plugins/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.h:5:
        In file included from /Users/loaner/Documents/IntelliJ_Projects/augmentalflutter/ios/Pods/Headers/Public/Flutter/Flutter/Flutter.h:37:
        In file included from Headers/Public/Flutter/Flutter/FlutterAppDelegate.h:10:
        Headers/Public/Flutter/Flutter/FlutterMacros.h:30:48: note: expanded from macro 'FLUTTER_DEPRECATED'
        #define FLUTTER_DEPRECATED(msg) __attribute__((__deprecated__(msg)))
                                                       ^
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:125:35: error: cannot find interface declaration for 'FlutterStandardWriter', superclass of 'FirestoreWriter'
        @implementation FirestoreWriter : FlutterStandardWriter
                                          ^
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:128:11: error: no visible @interface for 'FirestoreWriter' declares the selector 'writeByte:'
            [self writeByte:DATE_TIME];
             ~~~~ ^~~~~~~~~
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:132:11: error: no visible @interface for 'FirestoreWriter' declares the selector 'writeBytes:length:'
            [self writeBytes:&ms length:8];
             ~~~~ ^~~~~~~~~~~~~~~~~~~~~
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:137:11: error: no visible @interface for 'FirestoreWriter' declares the selector 'writeByte:'
            [self writeByte:GEO_POINT];
             ~~~~ ^~~~~~~~~
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:138:11: error: no visible @interface for 'FirestoreWriter' declares the selector 'writeAlignment:'
            [self writeAlignment:8];
             ~~~~ ^~~~~~~~~~~~~~
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:139:11: error: no visible @interface for 'FirestoreWriter' declares the selector 'writeBytes:length:'
            [self writeBytes:(UInt8 *)&latitude length:8];
             ~~~~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:140:11: error: no visible @interface for 'FirestoreWriter' declares the selector 'writeBytes:length:'
            [self writeBytes:(UInt8 *)&longitude length:8];
             ~~~~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:144:11: error: no visible @interface for 'FirestoreWriter' declares the selector 'writeByte:'
            [self writeByte:DOCUMENT_REFERENCE];
             ~~~~ ^~~~~~~~~
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:145:11: error: no visible @interface for 'FirestoreWriter' declares the selector 'writeUTF8:'
            [self writeUTF8:documentPath];
             ~~~~ ^~~~~~~~~
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:147:12: error: no visible @interface for 'FlutterStandardBigInteger' declares the selector 'writeValue:'
            [super writeValue:value];
             ~~~~~ ^~~~~~~~~~
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:152:30: error: cannot find interface declaration for 'FlutterStandardReader', superclass of 'FirestoreReader'
        @interface FirestoreReader : FlutterStandardReader
        ~~~~~~~~~~~~~~~~~~~~~~~~~~   ^
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:161:13: error: no visible @interface for 'FirestoreReader' declares the selector 'readBytes:length:'
              [self readBytes:&value length:8];
               ~~~~ ^~~~~~~~~~~~~~~~~~~~~~~
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:168:13: error: no visible @interface for 'FirestoreReader' declares the selector 'readAlignment:'
              [self readAlignment:8];
               ~~~~ ^~~~~~~~~~~~~
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:169:13: error: no visible @interface for 'FirestoreReader' declares the selector 'readBytes:length:'
              [self readBytes:&latitude length:8];
               ~~~~ ^~~~~~~~~~~~~~~~~~~~~~~~~~
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:170:13: error: no visible @interface for 'FirestoreReader' declares the selector 'readBytes:length:'
              [self readBytes:&longitude length:8];
               ~~~~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:174:38: error: no visible @interface for 'FirestoreReader' declares the selector 'readUTF8'
              NSString *documentPath = [self readUTF8];
                                        ~~~~ ^~~~~~~~
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:178:15: error: 'FirestoreReader' cannot use 'super' because it is a root class
              return [super readValueOfType:type];
                      ^
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:152:12: error: class 'FirestoreReader' defined without specifying a base class [-Werror,-Wobjc-root-class]
        @interface FirestoreReader : FlutterStandardReader
                   ^
        /Users/loaner/.pub-cache/hosted/pub.dartlang.org/cloud_firestore-0.3.2/ios/Classes/CloudFirestorePlugin.m:152:27: note: add a super class to fix this problem
        @interface FirestoreReader : FlutterStandardReader
                                  ^
                                   : NSObject 
        fatal error: too many errors emitted, stopping now [-ferror-limit=]
        6 warnings and 20 errors generated.
    Encountered error while building for device. `

我还有一张我在Xcode中遇到的错误的截图。请帮忙。 screenshot

0 个答案:

没有答案