0

When I try to build my react-native app with Xcode I get the following error:

building for iOS Simulator, but linking in dylib built for iOS, file '/Users/username/Projects/mono/apps/mobile/ios/Pods/hermes-engine/destroot/Library/Frameworks/iphoneos/hermes.framework/hermes' for architecture arm64

All I find is to start Xcode with rosetta which should fix this issue, but when I start Xcode with rosetta I get the following error:

/Users/user/Projects/mono/apps/mobile/ios/Mobile.xcodeproj The linked library 'libPods-Mobile.a' is missing one or more architectures required by this target: x86_64.

I then deleted the Pods and the Podfile.lock and reinstall the pods arch -x86_64 pod install but the issue is still the same.

Did anyone have a solution on how to run the react-native application on my m1?

Antoni
  • 1,170
  • 2
  • 11
  • 34

1 Answers1

0

remove pods folder and podfile.lock again and run following command

  • sudo gem install cocoapods-clean
  • pod deintegrate
  • pod clean
  • pod install
tiwari
  • 1
  • 2