My app uses a concurrency framework and targets iOS 14 and all toggles with Enable Bitcode in Build Settings are set to YES, after compiling it shows the following warnings (using SPM for dependencies):
ld: warning: all bitcode will be dropped because '/Build/Products/Debug-iphonesimulator/FirebaseFirestore.o' was built without bitcode. You must rebuild it with bitcode enabled (Xcode setting ENABLE_BITCODE), obtain an updated library from the vendor, or disable bitcode for this target.
Xcode 13.3 Release Notes:
Known Issues: Exporting an app that uses Swift’s concurrency features from an archive with bitcode might fail when the app targets iOS 13.0 – iOS 14.7, watchOS 6.0 – watchOS 7.6, or tvOS 13.0 – 14.7. (89271047) Workaround: Either uncheck the box Rebuild from bitcode when exporting the app from an archive or disable bitcode (iOS only).
It seems to me that Xcode force disables bitcode because of the backward compatibility of the concurrency feature. Is there a way to use async/await and enable bitcode? (Xcode 13.4 didn't solve the issue)
CodePudding user response:
The issue was fixed with Xcode 13.3.1
Apple Clang Compiler Resolved Issues Fixed: Exporting an app that uses Swift’s concurrency features from an archive with bitcode might fail when the app targets iOS 13.0–14.7, watchOS 6.0–7.6, or tvOS 13.0–14.7. (89271047) When you target iOS 13.4 and later and enable bitcode, the bitcode segment is now stripped correctly. This fixes a crash that prevented some apps from running in older operating systems (iOS 14 and earlier). (90024354) (FB9951126)
https://developer.apple.com/documentation/xcode-release-notes/xcode-13_3_1-release-notes
13.4 is available in the AppStore now. There isn't anything in the release notes about it reappearing.
CodePudding user response:
Today I added AdServices.framework to Link Binary With Libraries Build Phase and now I can switch on the Include Bitcode toggle when archiving. So the problem must be not with an Xcode