Failed to build module 'Razorpay' from its module interface

2.7k views Asked by At

Build failed with the following errors:

failed to build module 'Razorpay' from its module interface; the compiler that produced it, 'Apple Swift version 5.2.4 (swiftlang-1103.0.32.9 clang-1103.0.32.53)', may have used features that aren't supported by this compiler, 'Apple Swift version 5.3 (swiftlang-1200.0.29.2 clang-1200.0.30.1)'

and

<unknown>:0: error: unable to load standard library for target 'arm64-apple-ios10.0'

Razorpay pod Version :

pod 'razorpay-pod', '1.1.7'

Xcode Version :

Version 12.0.1 (12A7300)

I was working on our code which was earlier build on xcode 10 and razorpay pod was 1.1.1. With xcode 12 it was failing so I updated rayzorpay-pod 1.1.7

followed instruction is given in the documentation changed var razorpay: Razorpay! to var razorpay: RazorpayCheckout! and initWithKey function as well

1

There are 1 answers

2
Mahendra On BEST ANSWER

The razor pay pod is not compatible with Xcode 12.

The razor pay pod v1.1.9 is in pre-release(See below image) which is Xcode 12 complied version.

enter image description here

What you can do is just update the razor pay pod version to 1.1.7 to 1.1.9 and give it a try.

Or you can use razor pay pod v1.1.8(stable release) in lower than Xcode 12 version and when v1.1.9 is available you can move it Xcode 12.

You can do the following to use v1.1.9...

  • Comment the razor pay pod from pod file.

    #pod 'razorpay-pod', '1.1.7'
    
  • Run pod install command from terminal

  • Now razor pay pod is removed from your project.

  • Now add pod which is Xcode 12 compatible.

    pod 'razorpay-pod', '1.1.9'

  • Run pod install command

  • Build your project. If it succeeds you can move on, if not, then you have to downgrade Xcode version until v1.1.9 is fully available.