Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Xcode 12.5 causing CompileC build command failure on Flipper-Folly pod #155

Open
1 task
AlexHooperDev opened this issue Apr 27, 2021 · 34 comments
Open
1 task

Comments

@AlexHooperDev
Copy link

Environment

System:
    OS: macOS 11.3
    CPU: (16) x64 Intel(R) Core(TM) i9-9980HK CPU @ 2.40GHz
    Memory: 1.65 GB / 32.00 GB
    Shell: 5.8 - /bin/zsh
  Binaries:
    Node: 12.18.3 - /var/folders/v6/c3r2djmd7r51n2zbt82r59r80000gn/T/yarn--1619527993921-0.11460043057082148/node
    Yarn: 1.22.4 - /var/folders/v6/c3r2djmd7r51n2zbt82r59r80000gn/T/yarn--1619527993921-0.11460043057082148/yarn
    npm: 6.14.6 - ~/.nvm/versions/node/v12.18.3/bin/npm
    Watchman: Not Found
  Managers:
    CocoaPods: 1.9.3 - /usr/local/bin/pod
  SDKs:
    iOS SDK:
      Platforms: iOS 14.5, DriverKit 20.4, macOS 11.3, tvOS 14.5, watchOS 7.4
    Android SDK:
      API Levels: 28, 29, 30
      Build Tools: 28.0.3, 29.0.2, 29.0.3, 30.0.1
      System Images: android-29 | Intel x86 Atom_64, android-30 | Google APIs Intel x86 Atom, android-30 | Google Play Intel x86 Atom
      Android NDK: Not Found
  IDEs:
    Android Studio: 4.0 AI-193.6911.18.40.6626763
    Xcode: 12.5/12E262 - /usr/bin/xcodebuild
  Languages:
    Java: 1.8.0_265 - /usr/bin/javac
    Python: 2.7.16 - /usr/bin/python
  npmPackages:
    @react-native-community/cli: Not Found
    react: 16.13.1 => 16.13.1 
    react-native: 0.63.2 => 0.63.2 
    react-native-macos: Not Found

Things I’ve done to figure out my issue

Upgrading version

Description

After updating Xcode to 12.5, when trying to run my app for development in a simulator (iOS 14.5), I get the following error:

The following build commands failed:
        CompileC /Users/alex.hooper/Library/Developer/Xcode/DerivedData/Espresso-brgntaoyjolqyfdzcsunjlqtzzum/Build/Intermediates.noindex/Pods.build/Debug-iphoneos/Flipper-Folly.build/Objects-normal/arm64/DistributedMutex.o /Users/alex.hooper/Documents/figloo-bank-mobile/ios/Pods/Flipper-Folly/folly/synchronization/DistributedMutex.cpp normal arm64 c++ com.apple.compilers.llvm.clang.1_0.compiler

I have tried updating the flipper-folly pods to 2.5.1 and specifying this in my podfile with use_flipper!({ 'Flipper-Folly' => '2.5.1' }) however this has not solved the issue. I have also tried deleting my podfile.lock file, clearing the pod cache and that has not helped either.

Reproducible demo

@kristijantomic
Copy link

kristijantomic commented Apr 27, 2021

Also have an issue with Flipper-Folly :(

The following build commands failed:
	CompileC /Users/kristijan/Library/Developer/Xcode/DerivedData/awsmbox-cruawfsnqeumjxaasoueychfhhsl/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/Flipper-Folly.build/Objects-normal/x86_64/DistributedMutex.o /Users/kristijan/projects/awsmbox/ios/Pods/Flipper-Folly/folly/synchronization/DistributedMutex.cpp normal x86_64 c++ com.apple.compilers.llvm.clang.1_0.compiler
(1 failure)

Screenshot 2021-04-27 at 21 20 21

I tried facebook/react-native#26118 (comment)
and https://stackoverflow.com/a/66875279/3501012
but none help to have app up and running.

@tolacambo
Copy link

tolacambo commented Apr 28, 2021

Also had an issue with Flipper-Folly for new Xcode version 12.5.
I resolved this issue by commending these code in Podfile:

# use_flipper!
# post_install do |installer|
# flipper_post_install(installer)
# end

@kristijantomic
Copy link

More detailed discussion: facebook/react-native#31179

@levansonqs
Copy link

Also had an issue with Flipper-Folly for new Xcode version 12.5.
I resolved this issue by commending these code in Podfile:

# use_flipper!
# post_install do |installer|
# flipper_post_install(installer)
# end

it's work for me!

@sonmybbp05
Copy link

Also had an issue with Flipper-Folly for new Xcode version 12.5.
I resolved this issue by commending these code in Podfile:

# use_flipper!
# post_install do |installer|
# flipper_post_install(installer)
# end

It's work !
Thx.

@israelouteiro
Copy link

israelouteiro commented May 11, 2021

Solution without losing Flipper functionality:

Define the upgraded dependencies for Flipper in the Podfile

React Native 62

def add_flipper_pods!(versions = {})
  versions['Flipper'] ||= '~> 0.87.0' 
  versions['DoubleConversion'] ||= '1.1.7'
  versions['Flipper-Folly'] ||= '~> 2.5.3' 
  versions['Flipper-Glog'] ||= '0.3.6'
  versions['Flipper-PeerTalk'] ||= '~> 0.0.4'
  versions['Flipper-RSocket'] ||= '~> 1.3.1' 

React Native 63

  use_flipper!({'Flipper' => '0.87.0' , 'Flipper-Folly' => '2.5.3' , 'Flipper-RSocket' => '1.3.1' })
  post_install do |installer|
    flipper_post_install(installer)
  end

cd ios && pod install and you should be good to go

React Native 64

Bump the version to 0.64.1 in the package.json

yarn install && pod install --repo-update && react-native run-ios

https://github.com/facebook/react-native/releases/tag/v0.64.1

reference link: https://stackoverflow.com/a/67401311/6776378

@josmithua
Copy link

Also had an issue with Flipper-Folly for new Xcode version 12.5.
I resolved this issue by commending these code in Podfile:

# use_flipper!
# post_install do |installer|
# flipper_post_install(installer)
# end

I still had FB_SONARKIT_ENABLED set to 1 in xcode, so my build was failing. I had to remove it.

@AviIhej
Copy link

AviIhej commented May 13, 2021

This worked for me without having to comment out flipper-folly in the podfile:

use_flipper!({'Flipper' => '0.87.0' , 'Flipper-Folly' => '2.5.3' , 'Flipper-RSocket' => '1.3.1' })
post_install do |installer|
flipper_post_install(installer)
end

Then:
delete podfiles folder
delete podfile.lock
pod install --repo-update

I'm running:
React Native Version: 0.64.0
Xcode version: 12.5

Hope this helps 👍

@ismathim
Copy link

ismathim commented May 17, 2021

I solved this issue by commenting out 'use_flipper!' in the Podfile.

#use_flipper!
#post_install do |installer|
#flipper_post_install(installer)
#end

@HakimMaz
Copy link

Environment

System:
    OS: macOS 11.3
    CPU: (16) x64 Intel(R) Core(TM) i9-9980HK CPU @ 2.40GHz
    Memory: 1.65 GB / 32.00 GB
    Shell: 5.8 - /bin/zsh
  Binaries:
    Node: 12.18.3 - /var/folders/v6/c3r2djmd7r51n2zbt82r59r80000gn/T/yarn--1619527993921-0.11460043057082148/node
    Yarn: 1.22.4 - /var/folders/v6/c3r2djmd7r51n2zbt82r59r80000gn/T/yarn--1619527993921-0.11460043057082148/yarn
    npm: 6.14.6 - ~/.nvm/versions/node/v12.18.3/bin/npm
    Watchman: Not Found
  Managers:
    CocoaPods: 1.9.3 - /usr/local/bin/pod
  SDKs:
    iOS SDK:
      Platforms: iOS 14.5, DriverKit 20.4, macOS 11.3, tvOS 14.5, watchOS 7.4
    Android SDK:
      API Levels: 28, 29, 30
      Build Tools: 28.0.3, 29.0.2, 29.0.3, 30.0.1
      System Images: android-29 | Intel x86 Atom_64, android-30 | Google APIs Intel x86 Atom, android-30 | Google Play Intel x86 Atom
      Android NDK: Not Found
  IDEs:
    Android Studio: 4.0 AI-193.6911.18.40.6626763
    Xcode: 12.5/12E262 - /usr/bin/xcodebuild
  Languages:
    Java: 1.8.0_265 - /usr/bin/javac
    Python: 2.7.16 - /usr/bin/python
  npmPackages:
    @react-native-community/cli: Not Found
    react: 16.13.1 => 16.13.1 
    react-native: 0.63.2 => 0.63.2 
    react-native-macos: Not Found

Things I’ve done to figure out my issue

Upgrading version

Description

After updating Xcode to 12.5, when trying to run my app for development in a simulator (iOS 14.5), I get the following error:

The following build commands failed:
        CompileC /Users/alex.hooper/Library/Developer/Xcode/DerivedData/Espresso-brgntaoyjolqyfdzcsunjlqtzzum/Build/Intermediates.noindex/Pods.build/Debug-iphoneos/Flipper-Folly.build/Objects-normal/arm64/DistributedMutex.o /Users/alex.hooper/Documents/figloo-bank-mobile/ios/Pods/Flipper-Folly/folly/synchronization/DistributedMutex.cpp normal arm64 c++ com.apple.compilers.llvm.clang.1_0.compiler

I have tried updating the flipper-folly pods to 2.5.1 and specifying this in my podfile with use_flipper!({ 'Flipper-Folly' => '2.5.1' }) however this has not solved the issue. I have also tried deleting my podfile.lock file, clearing the pod cache and that has not helped either.

Reproducible demo

use @tolacambo solutions, comment flipper than , "pod install" , and the run ios

@oh-dev-life
Copy link

Also had an issue with Flipper-Folly for new Xcode version 12.5.
I resolved this issue by commending these code in Podfile:

# use_flipper!
# post_install do |installer|
# flipper_post_install(installer)
# end

thank a lot, you save my day!

@WilbertJanney
Copy link

WilbertJanney commented May 25, 2021

Solution without losing Flipper functionality:

Define the upgraded dependencies for Flipper in the Podfile

React Native 62

def add_flipper_pods!(versions = {})
  versions['Flipper'] ||= '~> 0.87.0' 
  versions['DoubleConversion'] ||= '1.1.7'
  versions['Flipper-Folly'] ||= '~> 2.5.3' 
  versions['Flipper-Glog'] ||= '0.3.6'
  versions['Flipper-PeerTalk'] ||= '~> 0.0.4'
  versions['Flipper-RSocket'] ||= '~> 1.3.1' 

React Native 63

  use_flipper!({'Flipper' => '0.87.0' , 'Flipper-Folly' => '2.5.3' , 'Flipper-RSocket' => '1.3.1' })
  post_install do |installer|
    flipper_post_install(installer)
  end

cd ios && pod install and you should be good to go

React Native 64

Bump the version to 0.64.1 in the package.json

yarn install && pod install --repo-update && react-native run-ios

https://github.com/facebook/react-native/releases/tag/v0.64.1

reference link: https://stackoverflow.com/a/67401311/6776378

I tried your instructions for version 0.62 of React, but now I got a different error

CompileC /Users/<redacted>/Library/Developer/Xcode/DerivedData/<redacted>-envzotmcabgxzwadohlifdiqmzql/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/React-Core.build/Objects-normal/x86_64/RCTCxxBridge.o /Users/<redacted>/Git\ Projects/<redacted>/node_modules/react-native/React/CxxBridge/RCTCxxBridge.mm normal x86_64 objective-c++ com.apple.compilers.llvm.clang.1_0.compiler

Any other things I have to change? Maybe having to upgrade the React Native version? Maybe downgrade my Xcode to 12.4? That's what I am going to try next.

@jerus1403
Copy link

Also had an issue with Flipper-Folly for new Xcode version 12.5.
I resolved this issue by commending these code in Podfile:

# use_flipper!
# post_install do |installer|
# flipper_post_install(installer)
# end

After commented the code. Follow these steps and it worked fine.
rm -rf node_modules
rm -rf Pods
Delete Podfile.lock
npm install
cd ios
pod install

flohhhh pushed a commit to cozy/cozy-flagship-app that referenced this issue Jun 5, 2021
With xcode 12.5 we can't build the app so
we must specify certain versions of Flipper.

Steps:
`cd ios`
`rm -rf Pods && rm Podfile.lock && pod install`
`cd .. && yarn ios`

Error:

** BUILD FAILED **

The following build commands failed:
	CompileC /Users/florianpires/Library/Developer/Xcode/DerivedData/CozyReactNative-devalkixoycmfgemernyouwwxlia/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/Flipper.build/Objects-normal/x86_64/FlipperRSocketResponder.o /Users/florianpires/Developer/cozy/cozy-react-native/ios/Pods/Flipper/xplat/Flipper/FlipperRSocketResponder.cpp normal x86_64 c++ com.apple.compilers.llvm.clang.1_0.compiler
(1 failure)

Issue: react-native-community/upgrade-support#155
@kranczeer
Copy link

Solution without losing Flipper functionality:

Define the upgraded dependencies for Flipper in the Podfile

React Native 62

def add_flipper_pods!(versions = {})
  versions['Flipper'] ||= '~> 0.87.0' 
  versions['DoubleConversion'] ||= '1.1.7'
  versions['Flipper-Folly'] ||= '~> 2.5.3' 
  versions['Flipper-Glog'] ||= '0.3.6'
  versions['Flipper-PeerTalk'] ||= '~> 0.0.4'
  versions['Flipper-RSocket'] ||= '~> 1.3.1' 

React Native 63

  use_flipper!({'Flipper' => '0.87.0' , 'Flipper-Folly' => '2.5.3' , 'Flipper-RSocket' => '1.3.1' })
  post_install do |installer|
    flipper_post_install(installer)
  end

cd ios && pod install and you should be good to go

React Native 64

Bump the version to 0.64.1 in the package.json
yarn install && pod install --repo-update && react-native run-ios
https://github.com/facebook/react-native/releases/tag/v0.64.1
reference link: https://stackoverflow.com/a/67401311/6776378

I tried your instructions for version 0.62 of React, but now I got a different error

CompileC /Users/<redacted>/Library/Developer/Xcode/DerivedData/<redacted>-envzotmcabgxzwadohlifdiqmzql/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/React-Core.build/Objects-normal/x86_64/RCTCxxBridge.o /Users/<redacted>/Git\ Projects/<redacted>/node_modules/react-native/React/CxxBridge/RCTCxxBridge.mm normal x86_64 objective-c++ com.apple.compilers.llvm.clang.1_0.compiler

Any other things I have to change? Maybe having to upgrade the React Native version? Maybe downgrade my Xcode to 12.4? That's what I am going to try next.

Hello, I have exactly the same error. Did you resolve it?

@jerus1403
Copy link

Yes I followed those steps with the commands and it worked.

@droplessjordan
Copy link

Getting the same error on react native 0.64.2 and xcode 12.5.1

@bimemto
Copy link

bimemto commented Jun 23, 2021

Getting the same error on react native 0.64.2 and xcode 12.5.1

same here, spent all my day and still can't figure out :(

@droplessjordan
Copy link

Getting the same error on react native 0.64.2 and xcode 12.5.1

same here, spent all my day and still can't figure out :(

@bimemto I used https://react-native-community.github.io/upgrade-helper/ and noticed I was missing somethings. I downgraded to react native 0.64.1 and added the following to my Podfile:

platform :ios, '11.0'

pod 'Stripe', '~> 19.4.0'

  use_flipper!()
  post_install do |installer|
    react_native_post_install(installer)
  end

and it worked. Hope it does for you too!

@bimemto
Copy link

bimemto commented Jun 23, 2021

Getting the same error on react native 0.64.2 and xcode 12.5.1

same here, spent all my day and still can't figure out :(

@bimemto I used https://react-native-community.github.io/upgrade-helper/ and noticed I was missing somethings. I downgraded to react native 0.64.1 and added the following to my Podfile:

platform :ios, '11.0'

pod 'Stripe', '~> 19.4.0'

  use_flipper!()
  post_install do |installer|
    react_native_post_install(installer)
  end

and it worked. Hope it does for you too!

Thanks for your response. I have tried but no luck. FYI I am on Macbook M1 chip

@mikepaszkiewicz
Copy link

@droplessjordan Awesome - the Podfile change did the trick for me - thank you so much!!

XCode 12.5, React Native 0.64.1, Big Sur

@manueleco
Copy link

Also had an issue with Flipper-Folly for new Xcode version 12.5.
I resolved this issue by commending these code in Podfile:

# use_flipper!
# post_install do |installer|
# flipper_post_install(installer)
# end

It works for me too!

@jerus1403
Copy link

Try to delete the DerivedData file then follow the above steps.

@BladeRunner1988
Copy link

Solution without losing Flipper functionality:

Define the upgraded dependencies for Flipper in the Podfile

React Native 62

def add_flipper_pods!(versions = {})
  versions['Flipper'] ||= '~> 0.87.0' 
  versions['DoubleConversion'] ||= '1.1.7'
  versions['Flipper-Folly'] ||= '~> 2.5.3' 
  versions['Flipper-Glog'] ||= '0.3.6'
  versions['Flipper-PeerTalk'] ||= '~> 0.0.4'
  versions['Flipper-RSocket'] ||= '~> 1.3.1' 

React Native 63

  use_flipper!({'Flipper' => '0.87.0' , 'Flipper-Folly' => '2.5.3' , 'Flipper-RSocket' => '1.3.1' })
  post_install do |installer|
    flipper_post_install(installer)
  end

cd ios && pod install and you should be good to go

React Native 64

Bump the version to 0.64.1 in the package.json

yarn install && pod install --repo-update && react-native run-ios

https://github.com/facebook/react-native/releases/tag/v0.64.1

reference link: https://stackoverflow.com/a/67401311/6776378

Thanks a lot... This worked for me... I found the React-Native version (version 0.63.4) from package.json file that was in the "node_modules/react-native/" folder and then followed the suggested solution...

@kapilfromuraan
Copy link

Also had an issue with Flipper-Folly for new Xcode version 12.5. I resolved this issue by commending these code in Podfile:

# use_flipper! # post_install do |installer| # flipper_post_install(installer) # end

Worked for me. Thanks

@glesperance
Copy link

Any solution that works with react-native v0.66.0?

@kondratjev
Copy link

Any solution that works with react-native v0.66.0?

Update react-native-reanimated to 2.3.0-beta.2 or higher.

@MatkoMilic
Copy link

Still doesnt work for me. RN 0.66 it didnt work few weeks ago, any of these fixes, neither it works today when im making another app. I'll again use RN 0.63 but its somewhat sad.

@MatkoMilic
Copy link

Even in RN 0.63 it completely prevents me from running on iOS simulator. However, commenting out use_flipper! all the way to the end, in podfile does "solve" it on 0.63.

@egenedy97
Copy link

image
image
I tried to use flipper but without any response

@Jayvish100
Copy link

This somehow worked for me. I don't know how it happened so I will share the steps I did.

after the Flipper error I comment just this line in ios/Podfile

# use_flipper!()

image

and did pod install which removed the flipper dependencies.

image

then run the project "npx react-native run-ios"

then project is successfully working now so then I removed the comment of flipper and and did the pod install again

image

image

And This is it.

I hope this helps.

some version Info:-

node: 16.13.2 (LTS)
npm: 8.1.2

package.json:-

"dependencies": {
"react": "17.0.2",
"react-native": "0.67.2",
},
"devDependencies": {
"@babel/core": "7.16.12",
"@babel/runtime": "7.16.7",
"@react-native-community/eslint-config": "2.0.0",
"babel-jest": "26.6.3",
"eslint": "7.14.0",
"jest": "26.6.3",
"metro-react-native-babel-preset": "0.66.2",
"react-test-renderer": "17.0.2"
},

@SRD75
Copy link

SRD75 commented Feb 11, 2022

I tried @Jayvish100 's solution, but the same error occurred. I am on an M1 Mac too.

npm 8.3.1
node 17.4
react 17.0.2
react-native 0.67.2

The error I receive is:

The following build commands failed:
        CompileC /Users/Steven/Library/Developer/Xcode/DerivedData/HelloSteve-hghgfcwemhoaiacfwlophutqqzbh/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RCT-Folly.build/Objects-normal/arm64/SysUio.o /Users/Steven/Documents/Projects/React\ Native/HelloSteve/ios/Pods/RCT-Folly/folly/portability/SysUio.cpp normal arm64 c++ com.apple.compilers.llvm.clang.1_0.compiler (in target 'RCT-Folly' from project 'Pods')

@namansamra
Copy link

I got the same error. Did you get any solution ?

@Peteryar
Copy link

use_flipper!({'Flipper' => '0.87.0' , 'Flipper-Folly' => '2.5.3' , 'Flipper-RSocket' => '1.3.1' })
post_install do |installer|
flipper_post_install(installer)
end

this worked for me, just hoping I will not loose functionality commenting out flipper

@Gautamshah1
Copy link

i am faceing the error
while my react native is 71
i am using 13 ios
i had commented the flipper but it doesnot work

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests