Home:ALL Converter>Flutter Xcode build failing because of Undefined symbols for architecture x86_64

Flutter Xcode build failing because of Undefined symbols for architecture x86_64

Ask Time:2022-12-06T23:42:02         Author:u2tall

Json Formatter

After updating dependencies I'm unable to make an iOS build/test on an iOS simulator. I've tried many different answers online for similar issues and nothing has worked. Any help or guidance at all would be appreciated. I've been working on this for a while now unsuccessfully.

Error with Xcode build:

Undefined symbols for architecture x86_64:
      "_OBJC_CLASS_$_FIRHeartbeatInfo", referenced from:
          objc-class-ref in FirebaseFirestore(firebase_metadata_provider_apple.o)
    ld: symbol(s) not found for architecture x86_64
Error (Xcode): Undefined symbol: _OBJC_CLASS_$_FIRHeartbeatInfo

Could not build the application for the simulator.
Error launching application on iPhone 11.

Firebase dependencies:

 # firebase
  firebase_core: ^2.3.0
  firebase_analytics: ^10.0.6
  firebase_crashlytics: ^3.0.6
  firebase_storage: ^11.0.6

Flutter Doctor:

[✓] Android toolchain - develop for Android devices (Android SDK version 31.0.0)
[✓] Xcode - develop for iOS and macOS (Xcode 14.1)
[✓] Chrome - develop for the web
[✓] Android Studio (version 2021.3)
[✓] Connected device (3 available)
[✓] HTTP Host Availability

• No issues found!

Some of the things I've tried:

  • Adding @(inherited) to several locations in the Xcode build settings
  • Flutter Clean & rebuild
sudo arch -x86_64 gem install ffi
arch -x86_64 pod install
Remove all pods cd ios && pod deintegrate
Reinstall all pods arch -x86_64 pod install

Author:u2tall,eproduced under the CC 4.0 BY-SA copyright license with a link to the original source and this disclaimer.
Link to original article:https://stackoverflow.com/questions/74705275/flutter-xcode-build-failing-because-of-undefined-symbols-for-architecture-x86-64
yy