upgrade-support icon indicating copy to clipboard operation
upgrade-support copied to clipboard

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

Open AlexHooperDev opened this issue 3 years ago • 34 comments

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

AlexHooperDev avatar Apr 27 '21 13:04 AlexHooperDev

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 https://github.com/facebook/react-native/issues/26118#issuecomment-525085809 and https://stackoverflow.com/a/66875279/3501012 but none help to have app up and running.

kristijantomic avatar Apr 27 '21 19:04 kristijantomic

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

tolacambo avatar Apr 28 '21 04:04 tolacambo

More detailed discussion: https://github.com/facebook/react-native/issues/31179

kristijantomic avatar Apr 28 '21 05:04 kristijantomic

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!

levansonqs avatar May 05 '21 11:05 levansonqs

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.

sonmybbp05 avatar May 06 '21 16:05 sonmybbp05

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

israelouteiro avatar May 11 '21 20:05 israelouteiro

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.

josmithua avatar May 12 '21 19:05 josmithua

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 👍

AviIhej avatar May 13 '21 20:05 AviIhej

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

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

ismathim avatar May 17 '21 07:05 ismathim

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

HakimMaz avatar May 24 '21 09:05 HakimMaz

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!

oh-dev-life avatar May 24 '21 15:05 oh-dev-life

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.

WilbertJanney avatar May 25 '21 14:05 WilbertJanney

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

jerus1403 avatar Jun 04 '21 15:06 jerus1403

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?

kranczeer avatar Jun 12 '21 22:06 kranczeer

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

jerus1403 avatar Jun 19 '21 20:06 jerus1403

Getting the same error on react native 0.64.2 and xcode 12.5.1

droplessjordan avatar Jun 22 '21 14:06 droplessjordan

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 avatar Jun 23 '21 07:06 bimemto

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!

droplessjordan avatar Jun 23 '21 07:06 droplessjordan

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

bimemto avatar Jun 23 '21 14:06 bimemto

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

XCode 12.5, React Native 0.64.1, Big Sur

mikepaszkiewicz avatar Jun 23 '21 16:06 mikepaszkiewicz

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!

manueleco avatar Jun 24 '21 00:06 manueleco

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

jerus1403 avatar Jun 24 '21 03:06 jerus1403

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...

BladeRunner1988 avatar Sep 11 '21 23:09 BladeRunner1988

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

kapilfromuraan avatar Oct 04 '21 17:10 kapilfromuraan

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

glesperance avatar Oct 05 '21 15:10 glesperance

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

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

kondratjev avatar Oct 08 '21 18:10 kondratjev

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 avatar Oct 26 '21 12:10 MatkoMilic

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.

MatkoMilic avatar Oct 26 '21 13:10 MatkoMilic

image image I tried to use flipper but without any response

egenedy97 avatar Nov 03 '21 15:11 egenedy97

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" },

Jayvish100 avatar Feb 02 '22 08:02 Jayvish100