React Native Xcode Project Product Archive Fails with Duplicate Symbols for Architecture Arm64

React Native XCode Project Product Archive Fails with duplicate symbols for architecture arm64

Finally solved the problem after finding a relevant issue on another react-native project here.

The answer is that there is two copies of React Native in the Xcode project, one from CocoaPods and another as a subproject. Just remove all modules that were already declared in Podfile under the Libraries inside Xcode and the error goes away after a clean and re-try.

What's interesting about this issue is that all builds in Debug and Release works but it fails when attempting to Archive the project for distribution.

[Update 2 May 2017]

The solution I described above can cause debug-time errors when you run your code with react-native run-ios/android though it allows the project to be successfully archived.

An alternative method is to remove those duplicate modules that exist both in Libraries and Podfile from the Podfile declaration instead of the Libraries folder. And of course run the relevant pod commands, clean your project etc.

Doing this allowed my code to archive and also run without debug-time errors

Archive ReactNative got duplicate symbols for architecture arm64

Finally. I solved this problem!

Just remove all about React in PodFile (Only React) and everything become pretty

Duplicate Symbols for Architecture arm64

From the errors, it would appear that the FacebookSDK.framework already includes the Bolts.framework classes. Try removing the additional Bolts.framework from the project.

Xcode: ld: 275 duplicate symbols for architecture arm64 clang: error: linker command failed with exit code 1 (use -v to see invocation)

From the comments:

The errors say that you're linking libReact.a and libRCTWebSocket.a and that both of those contain the same class: RCTWebSocketModule.



Related Topics



Leave a reply



Submit