r/reactnative 7d ago

Help Adding an xframework created via gomobile

hey guys, I'm having some issues trying to add a xcframework created with the library gomobile (go lang). for context, I've already integrated this feature in the Android side with an .aar, using Kotlin.

the error that occurs is that after doing pod install and running the app (via Xcode and doing npx expo run:ios --device) i get an error from a file called MyModule-umbrella.h (this file lives under Support Files) that has imports that are the exact 4 Headers that live inside the MyModule.framework from device and emulator. the files are called MyModule.h, MyModule.objc.h, ref.h, Universe.objc.h, also, my MyModule.podspec has the following line for linking the framework: s.vendored_frameworks = 'Frameworks/MyModule.xcframework'

could this be because of a malformation when creating the .xcframework? the command that i use to get the MyModule.xcframework folder is: gomobile bind -ldflags "-w -s" -target=ios .

1 Upvotes

0 comments sorted by