Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Adding Testflight SDK: missing required architecture arm64 in file libTestFlight.a

I'm adding the Testflight SDK to my iOS project, but now I can't build the IPA for it.

The error I have is

 ld: warning: ignoring file     /Users/RM/Dropbox/SAM_iOS/mainApp/SAM/TestFlightSDK2/libTestFlight.a, missing required architecture arm64 in file /Users/RM/Dropbox/SAM_iOS/mainApp/SAM/TestFlightSDK2/libTestFlight.a (3 slices)
 Undefined symbols for architecture arm64:
 "_OBJC_CLASS_$_TestFlight", referenced from:
  objc-class-ref in AppDelegate.o
 ld: symbol(s) not found for architecture arm64
 clang: error: linker command failed with exit code 1 (use -v to see invocation)

I've followed (three times) the steps detailed here, but the error keeps appearing. Any help is appreciated!

like image 833
Sr.Richie Avatar asked Dec 26 '22 16:12

Sr.Richie


2 Answers

The 2.0.2 version of the TestFlight library does not support arm64.

You can either remove the arm64 from your project and targets or use the 2.1 beta library which has support for arm64

like image 190
rckoenes Avatar answered Apr 13 '23 00:04

rckoenes


You can check which architectures are included in the a library using the lipo tool in Terminal:

lipo -info <path to library>

Running this on version 2.0.2 of the library, shows that it does not include the arm64 architecture:

Architectures in the fat file: libTestFlight.a are: armv7 armv7s i386

Running the same on the 2.1.3 beta:

Architectures in the fat file: libTestFlight.a are: armv7 armv7s i386 x86_64 arm64

like image 29
neilco Avatar answered Apr 12 '23 23:04

neilco