After reading https://reactnative.dev/docs/environment-setup, I created a react-native project using npx react-native init ***
.
It was successful, so, I tried to run the project using npx react-native run-ios
, and got the below error:
** BUILD FAILED **
The following build commands failed:
CompileC /Users/loser/Library/Developer/Xcode/DerivedData/test0205-dasunahpjpavelgmslwgmvjhesxy/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/Flipper.build/Objects-normal/x86_64/FlipperRSocketResponder.o /Users/loser/Documents/projects/test0205/ios/Pods/Flipper/xplat/Flipper/FlipperRSocketResponder.cpp normal x86_64 c++ com.apple.compilers.llvm.clang.1_0.compiler
(1 failure)
16
Answers
It's because of
use_flipper
in Podfile for iOS project.So, I was needed to indicate
Flipper-Folly
version with use_flipper asIt worked perfectly after that change.
From mmemories, it’s necessary to execute
pod install
command before !This seems to be an issue in react-native 0.63, try initiating the project with –version 0.62 and it should work until they fix the bug
React version -0. 63
I am still facing the same issue while starting a new project for iOS in Mac. I have followed these steps given below but still the issue
After doin this I got the following error
Later I have changed in the pod file
use_flipper!
touse_flipper!({ 'Flipper-Folly' => '2.3.0' })
, but I’m still having the same issue.Here is a screenshot of the problem
Following Everest Climber answer
Change use_flipper! to use_flipper!({ ‘Flipper-Folly’ => ‘2.3.0’ })
This worked for me. Hopefully, it works for you too
use_flipper!
touse_flipper!({ 'Flipper-Folly' => '2.3.0' })
pod install
I could solve this issue after disabling Flipper in ios/Podfile.
For me disabling flipper from Podfile works!!
updated Podfile
cd ios && pod install
cd .. && npx react-native run-ios
Yes, Everest Climber is right. It’s broken after I updated my react-native-CLI. It’s because of the use_flipper new version.
Steps to fix it:
It’s worked for me perfectly.
How to fix:
This is caused by Flipper-Folly being broken on the latest Catalina build.
Until this gets patched, your best bet is to force your cocoapods to the latest working version (2.3.0).
Go to your project folder root and open the
/ios
directory.Open your
Podfile
and change the following block of code:to
Inside the
/ios
directory run the following command:If it worked, go back to your project root and try to run the project
in case it didn’t, check the Compatibility trouble-shooting section:
Compatibility trouble-shooting
After trying to run
pod install
you may have gotten a similar error to this:In order to solve this
Go back to your
/ios
folderAnd remove the
Podfile.lock
fileInstall the pods again
And run react-native
If nothing works, comment it.
I tried everything here and a lot more and nothing worked!
I then:
--legacy-peer-deps
for me),npx pod-install
(or cd ios/, pod-install)npx react-native run-ios
And it finally worked.
Apparently deleting the node_modules did the trick, but do not ask me why.
This issue is caused by flipper-folly pod spec updates
Remove/uninstall react-native-cli, just use npx
Try this on react-native 0.63.4 (previous stable version).
Remember it doesn’t work for latest 0.64.0 with XCode 12.5
Inside ios/Podfile replace use_flipper! with:
pod install –repo-update
npx react-native run-ios
if you don’t need to use flipper or still getting some issues try commenting out flipper inside podfile and install pods using command
you can easily comment out these lines to disable flipper :
and comment out this lines in
appDelegate.m
:also this in the same file:
The only fix worked for me
There is no need to disable flipper or juggle with its versions
add this to your Podfile in post_install section
it will look like this
then
remove
Pods
folder andPodfile.lock
run
pod install
build your app (
npx react-native run-ios
in the root folder of your app)Explanation
In my case the issue was the case sensitive file system. You can search in terminal for
fatal error: 'openssl/opensslv.h' file not found
or just try to build using this fix.use this in pod file. worked for me…
delete the podfile.lock then run,