question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Xcode build error on React Native 0.65.1

See original GitHub issue

Describe the bug Build not successful on React Native 0.65.1

To Reproduce Steps to reproduce the behavior:

  1. Initialize new react native project
  2. Install @stripe/stripe-react-native
  3. run pod install in project’s ios folder
  4. Open project workspace in Xcode and build

Expected behavior For brand new project the build process should be successful

Screenshots Screenshot 2021-09-27 at 08 14 44

Error’s in text format

Undefined symbols for architecture arm64:
  "protocol conformance descriptor for __C.NSOperationQueue : Combine.Scheduler in Foundation", referenced from:
      lazy protocol witness table accessor for type __C.NSOperationQueue and conformance __C.NSOperationQueue : Combine.Scheduler in Foundation in libStripe.a(URLSession+Retry.o)
  "type metadata accessor for (extension in Foundation):__C.NSOperationQueue.SchedulerTimeType", referenced from:
      closure #1 (Foundation.Data?, __C.NSURLResponse?, Swift.Error?) -> () in (extension in Stripe):__C.NSURLSession.stp_performDataTask(with: Foundation.URLRequest, completionHandler: (Foundation.Data?, __C.NSURLResponse?, Swift.Error?) -> (), retryCount: Swift.Int) -> () in libStripe.a(URLSession+Retry.o)
  "(extension in Foundation):__C.NSScanner.scanUpToString(Swift.String) -> Swift.String?", referenced from:
      static Stripe.STPPhoneNumberValidator.formattedRedactedPhoneNumber(for: Swift.String, forCountryCode: Swift.String?) -> Swift.String in libStripe.a(STPPhoneNumberValidator.o)
  "(extension in Foundation):__C.NSOperationQueue.SchedulerTimeType.init(Foundation.Date) -> (extension in Foundation):__C.NSOperationQueue.SchedulerTimeType", referenced from:
      closure #1 (Foundation.Data?, __C.NSURLResponse?, Swift.Error?) -> () in (extension in Stripe):__C.NSURLSession.stp_performDataTask(with: Foundation.URLRequest, completionHandler: (Foundation.Data?, __C.NSURLResponse?, Swift.Error?) -> (), retryCount: Swift.Int) -> () in libStripe.a(URLSession+Retry.o)
  "_swift_getOpaqueTypeConformance", referenced from:
      associated type witness table accessor for Body : SwiftUI.View in Stripe.PaymentSheet.PaymentButton<A> : SwiftUI.View in Stripe in libStripe.a(PaymentSheet+SwiftUI.o)
      associated type witness table accessor for Body : SwiftUI.View in Stripe.PaymentSheet.FlowController.PaymentOptionsButton<A> : SwiftUI.View in Stripe in libStripe.a(PaymentSheet+SwiftUI.o)
      associated type witness table accessor for Body : SwiftUI.View in Stripe.PaymentSheet.FlowController.ConfirmButton<A> : SwiftUI.View in Stripe in libStripe.a(PaymentSheet+SwiftUI.o)
      associated type witness table accessor for SwiftUI.ViewModifier.Body : SwiftUI.View in Stripe.PaymentSheet.PaymentSheetPresentationModifier : SwiftUI.ViewModifier in Stripe in libStripe.a(PaymentSheet+SwiftUI.o)
      associated type witness table accessor for SwiftUI.ViewModifier.Body : SwiftUI.View in Stripe.PaymentSheet.PaymentSheetFlowControllerPresentationModifier : SwiftUI.ViewModifier in Stripe in libStripe.a(PaymentSheet+SwiftUI.o)
      associated type witness table accessor for Body : SwiftUI.View in Stripe.ConfirmPaymentPresentationModifier<A, B> : SwiftUI.ViewModifier in Stripe in libStripe.a(STPPaymentConfirmation+SwiftUI.o)
  "__swift_FORCE_LOAD_$_swiftCoreMIDI", referenced from:
      __swift_FORCE_LOAD_$_swiftCoreMIDI_$_Stripe in libStripe.a(STPPaymentMethodGiropayParams.o)
      __swift_FORCE_LOAD_$_swiftCoreMIDI_$_Stripe in libStripe.a(STPPaymentMethodAUBECSDebit.o)
      __swift_FORCE_LOAD_$_swiftCoreMIDI_$_Stripe in libStripe.a(STPContactField.o)
      __swift_FORCE_LOAD_$_swiftCoreMIDI_$_Stripe in libStripe.a(ApplePayHeaderView.o)
      __swift_FORCE_LOAD_$_swiftCoreMIDI_$_Stripe in libStripe.a(BottomSheet3DS2ViewController.o)
      __swift_FORCE_LOAD_$_swiftCoreMIDI_$_Stripe in libStripe.a(STPThreeDSLabelCustomization.o)
      __swift_FORCE_LOAD_$_swiftCoreMIDI_$_Stripe in libStripe.a(ConfirmButton.o)
      ...
     (maybe you meant: __swift_FORCE_LOAD_$_swiftCoreMIDI_$_stripe_react_native, __swift_FORCE_LOAD_$_swiftCoreMIDI_$_Stripe )
  "__swift_FORCE_LOAD_$_swiftUniformTypeIdentifiers", referenced from:
      __swift_FORCE_LOAD_$_swiftUniformTypeIdentifiers_$_Stripe in libStripe.a(STPPaymentMethodGiropayParams.o)
      __swift_FORCE_LOAD_$_swiftUniformTypeIdentifiers_$_Stripe in libStripe.a(STPPaymentMethodAUBECSDebit.o)
      __swift_FORCE_LOAD_$_swiftUniformTypeIdentifiers_$_Stripe in libStripe.a(STPContactField.o)
      __swift_FORCE_LOAD_$_swiftUniformTypeIdentifiers_$_Stripe in libStripe.a(ApplePayHeaderView.o)
      __swift_FORCE_LOAD_$_swiftUniformTypeIdentifiers_$_Stripe in libStripe.a(BottomSheet3DS2ViewController.o)
      __swift_FORCE_LOAD_$_swiftUniformTypeIdentifiers_$_Stripe in libStripe.a(STPThreeDSLabelCustomization.o)
      __swift_FORCE_LOAD_$_swiftUniformTypeIdentifiers_$_Stripe in libStripe.a(ConfirmButton.o)
      ...
     (maybe you meant: __swift_FORCE_LOAD_$_swiftUniformTypeIdentifiers_$_stripe_react_native, __swift_FORCE_LOAD_$_swiftUniformTypeIdentifiers_$_Stripe )
  "__swift_FORCE_LOAD_$_swiftCoreML", referenced from:
      __swift_FORCE_LOAD_$_swiftCoreML_$_Stripe in libStripe.a(STPPaymentMethodGiropayParams.o)
      __swift_FORCE_LOAD_$_swiftCoreML_$_Stripe in libStripe.a(STPPaymentMethodAUBECSDebit.o)
      __swift_FORCE_LOAD_$_swiftCoreML_$_Stripe in libStripe.a(STPContactField.o)
      __swift_FORCE_LOAD_$_swiftCoreML_$_Stripe in libStripe.a(ApplePayHeaderView.o)
      __swift_FORCE_LOAD_$_swiftCoreML_$_Stripe in libStripe.a(BottomSheet3DS2ViewController.o)
      __swift_FORCE_LOAD_$_swiftCoreML_$_Stripe in libStripe.a(STPThreeDSLabelCustomization.o)
      __swift_FORCE_LOAD_$_swiftCoreML_$_Stripe in libStripe.a(ConfirmButton.o)
      ...
     (maybe you meant: __swift_FORCE_LOAD_$_swiftCoreML_$_stripe_react_native, __swift_FORCE_LOAD_$_swiftCoreML_$_Stripe )
  "__swift_FORCE_LOAD_$_swiftWebKit", referenced from:
      __swift_FORCE_LOAD_$_swiftWebKit_$_Stripe in libStripe.a(STPPaymentMethodGiropayParams.o)
      __swift_FORCE_LOAD_$_swiftWebKit_$_Stripe in libStripe.a(STPPaymentMethodAUBECSDebit.o)
      __swift_FORCE_LOAD_$_swiftWebKit_$_Stripe in libStripe.a(STPContactField.o)
      __swift_FORCE_LOAD_$_swiftWebKit_$_Stripe in libStripe.a(ApplePayHeaderView.o)
      __swift_FORCE_LOAD_$_swiftWebKit_$_Stripe in libStripe.a(BottomSheet3DS2ViewController.o)
      __swift_FORCE_LOAD_$_swiftWebKit_$_Stripe in libStripe.a(STPThreeDSLabelCustomization.o)
      __swift_FORCE_LOAD_$_swiftWebKit_$_Stripe in libStripe.a(ConfirmButton.o)
      ...
     (maybe you meant: __swift_FORCE_LOAD_$_swiftWebKit_$_stripe_react_native, __swift_FORCE_LOAD_$_swiftWebKit_$_Stripe )
ld: symbol(s) not found for architecture arm64

My working environment MacOs: v11.2 (Big Sur) Node: v14.16.1 React Native: v0.65.1 @stripe/stripe-react-native: v0.2.2

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:6

github_iconTop GitHub Comments

5reactions
takeerdevscommented, Oct 11, 2021

I found the solution, suggested solution didn’t work, you don’t even have to remove swift related entries, all you have to do is change ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES to Yes in Project->Build Settings

0reactions
krunalshoppikocommented, Feb 25, 2022

I found the solution, suggested solution didn’t work, you don’t even have to remove swift related entries, all you have to do is change ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES to Yes in Project->Build Settings

This one is also not working

Read more comments on GitHub >

github_iconTop Results From Across the Web

iOS build fails for RN upgrade 0.64.2 -> 0.65.1 #32097 - GitHub
Description I went through the upgrade helper for RN version 0.64.2 -> 0.65.1. Android build successful but iOS cannot build. React Native ......
Read more >
Xcode 12.2 / React Native 0.65 Build Fails, Any One Help Me ...
React Native IOS Issue: Xcode 12.2 / React Native 0.65 Build Fails, Any One Help Me to Build the IOS Version · 0...
Read more >
Xcode Build error with React Nativ… | Apple Developer Forums
I'm getting the following error when trying to build to a device in Xcode. It works fine on the simulator. Xcode 12.5 and...
Read more >
RNUILib 5.30.0 in React-Native 0.65.1 wont build due to error ...
allprojects { repositories { jcenter() google() mavenCentral() mavenLocal() maven { // All of React Native (JS, Obj-C sources, Android binaries) is ...
Read more >
Troubleshooting - React Native
If you run into issue where executing npm run android on macOS throws the above error, try to run sudo chmod +x android/gradlew...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found