Search code examples
iosxcodereact-nativesimulator

npx react-native run-ios fails


I'm trying to help a new team member to get our RN app working on his Simulator, from CLI or Xcode.

From the CLI, we are getting the following error:

Ld /Users/USERNAME/Library/Developer/Xcode/DerivedData/APPFOLDER-bxdehwlqvykiwgbwavwistqbnidi/Build/Products/Debug-iphonesimulator/APP.app/APP normal x86_64

We've tried all the standard solutions such as:

rm -rf ~/Library/Caches/CocoaPods
rm -rf Pods
rm -rf ~/Library/Developer/Xcode/DerivedData/*
pod deintegrate
pod setup / pod install

Also tried uncommenting the flipper!() in Podfile, and tinkering with Build Phases > Link Binary With Library in Xcode.

Macbook Pro M2, OS Monterey, Xcode 13.4.1

My own computer is an M1, and OS Monterey. I have never had this many problems with trying to start the Simulator.

Any advice will help. Thanks.


Solution

  • You may need to install Rosetta. However, you mentioned that you also have a m1. Didn't you have to install Rosetta for your application ?

    softwareupdate --install-rosetta
    

    Solved this issue for me in the past.

    Also you could try to create a separated RN app and check if you are having the same issue. ( If you do than the problem is not with rosetta). In this case I would review the steps https://reactnative.dev/docs/environment-setup