Errors related to SquareReader framework for iOS when building project in Xcode

Hello,

Some of my colleagues are seeing errors related to the squarereadersdk when building our app on Xcode:

ld: warning: ignoring file /Users/temp/code/myapp/Pods/SquareReaderSDK/SquareReaderSDK.framework/SquareReaderSDK, building for iOS Simulator-x86_64 but attempting to link with file built for unknown-unsupported file format ( 0x76 0x65 0x72 0x73 0x69 0x6F 0x6E 0x20 0x68 0x74 0x74 0x70 0x73 0x3A 0x2F 0x2F )
Undefined symbols for architecture x86_64:
  "_OBJC_CLASS_$_SQRDTender", referenced from:
      objc-class-ref in SquareService.o
  "_OBJC_CLASS_$_SQRDReaderSDK", referenced from:
      objc-class-ref in SquareService.o
  "_OBJC_CLASS_$_SQRDReaderSettingsController", referenced from:
      objc-class-ref in SquareService.o
  "_OBJC_CLASS_$_SQRDMoney", referenced from:
      objc-class-ref in SquareService.o
  "_OBJC_CLASS_$_SQRDCheckoutController", referenced from:
      objc-class-ref in SquareService.o
  "_OBJC_CLASS_$_SQRDCheckoutParameters", referenced from:
      objc-class-ref in SquareService.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

We’ve been trying for days to fix this. From cloning a brand new project to re-installing cocoapods, playing with the Xcode settings etc.

By the way, we are using the following version: pod 'SquareReaderSDK', '1.4.8'

Any help is appreciated.

Thanks.

Hi @rdrch welcome to the forums!

What version of XCode are you using? Also, Square Reader SDK doesn’t currently support Cocoa Pods as far as I’m aware, so I’m not sure where you’re getting the pod from. In our documentation we require you to run a ruby command to download the Reader SDK framework: https://developer.squareup.com/docs/reader-sdk/build-on-ios#step-2-install-reader-sdk.

Hi @sjosey,

Thanks for the prompt reply.

We use Xcode 11.7 and yes, you are right. What we did was install the SquareReaderSDK on a private pod and use it on our app via Cocoapods.

Thanks! I discussed this with a member of our iOS team and they mentioned it could be due to derived data within Xcode. Could you try deleting your derived data in Xcode and see if the issue is resolved? Here’s some info on how to do this just in case: https://stackoverflow.com/a/42760524.

I did that already and unfortunately the errors didn’t clear up. I deleted derived data, cleaned the project, deintegrated pods, re-ran pod install, and still same errors are showing.

It seems to be related to git lfs not being setup correctly.

Should we track specific framework files with git lfs? If yes, could you advise which ones?

Thanks!