2

I added Notification Extension Service for push notification image purpose. It can running on read device as expected

but when I tried to archive it, some errors appears, look like the following :

Undefined Symbol : OBJC_CLASS$_FlutterBasicMessageChannel

The error message :

Could not find or use auto-linked framework 'Flutter'

Undefined symbol: _FlutterMethodNotImplemented

Undefined symbol: _OBJC_CLASS_$_FlutterBasicMessageChannel

Undefined symbol: _OBJC_CLASS_$_FlutterError

Undefined symbol: _OBJC_CLASS_$_FlutterMethodChannel

Undefined symbol: _OBJC_CLASS_$_FlutterStandardMessageCodec

Undefined symbol: _OBJC_CLASS_$_FlutterStandardReader

Undefined symbol: _OBJC_CLASS_$_FlutterStandardReaderWriter

Undefined symbol: _OBJC_CLASS_$_FlutterStandardTypedData

Undefined symbol: _OBJC_CLASS_$_FlutterStandardWriter

Undefined symbol: _OBJC_METACLASS_$_FlutterStandardReader

Undefined symbol: _OBJC_METACLASS_$_FlutterStandardReaderWriter

Undefined symbol: _OBJC_METACLASS_$_FlutterStandardWriter

I have tried some solutions that provided on internet like :

1. TargetSettings -> Build Phases -> Compile Sources -> add your .m class  ->Build and Run
2. Set development target of extension must equal to runner's development target
3. Clean and build folder for severals time, but still doesn't work

Those solutions above have no good result, still face the errors.

Just info, I got this after update to XCode 14 and add Notification Extension Services

If there's any solution that I have to try, please let me know, I appreciate it very much.

Thank you

pmatatias
  • 3,491
  • 3
  • 10
  • 30
Yokaha
  • 31
  • 5

2 Answers2

1

After tried everything that possible, finally I able to solved my problem. The last thing that I tried was :

Change Project Runner Configuration for Release to NONE

Configuration for Runner

But, maybe this is not the final way to solve the similar problem. If above solutions don't work, the please try this solutions as well :

  1. TargetSettings -> Build Phases -> Compile Sources -> add your .m class ->Build and Run
  2. Set development target of extension must equal to runner's development target
  3. Target -> Runner -> Build Phases, scroll down and find Compile Resource -> Add your .m file
  4. Clean and build folder for severals time,

but don't forget to do Pod Update everytime you edit xcode component ( just to re-ensure everything is work )

I hope this solution can help other member who face the same issue.

Info, the issue come when i use this :

  • xCode 14
  • Notification service Extension
Yokaha
  • 31
  • 5
0

Please be sure that the extension does have the release variation build.

I faced this problem because I was running an "archive," the "Release" build variation is used, but the extension does not have this build variation. How can you add the release build variation to the extension? I continue creating when I add a new extension without using this build variation and the problem solved.

  • Actually I have several variant for my application ( dev, qa and prod). Could you please add more detail about your solution ( if possible please add step by step ) – Yokaha Nov 22 '22 at 09:48
  • I will just give me sometimes – Abdullatif Eida Nov 22 '22 at 11:30
  • please take a look to this issues (https://stackoverflow.com/questions/58001433/xcode-11-stuck-on-archiving/58355036#58355036) – Abdullatif Eida Nov 22 '22 at 11:35
  • I just followed step by step and set No Optimization ( onOne ) -> pod update -> clean & build -> archive -> failed with the same errors appears. is it related with xcode version 14? – Yokaha Nov 22 '22 at 12:08
  • in-fact I tried this solution with Xcode version 13 and worked for me, so the problem with Xcode 14 I will look and return when finding a solution – Abdullatif Eida Nov 22 '22 at 12:47
  • Okay, thank you. If there is any update please mention me here. I a bit frustrated with this configuration – Yokaha Nov 22 '22 at 13:04
  • @Yokaha is there any news actually I looked up but with out no findings. I am sorry bro – Abdullatif Eida Nov 22 '22 at 20:05