facebook-ios-sdk icon indicating copy to clipboard operation
facebook-ios-sdk copied to clipboard

FBAEMKit.framework/FBAEMKit' does not contain 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.

Open pradipaub36 opened this issue 2 years ago • 11 comments

Checklist before submitting a bug report

Xcode version

13.4.1

Facebook iOS SDK version

15.0

Dependency Manager

CocoaPods

SDK Framework

Other / I don't know

Goals

I am supposed to update the iOS SDK to the latest version 15.0 since this is the recommended version that needs to be updated!

Expected results

I should be able to update the Facebook SDK to the latest version 15.0 and login should work seamlessly as before. It forces me to disable the BITCODE but I don't want to disable it as I have integrated lots of other SDKs as well.

Actual results

I am getting errors while compiling the project

FBAEMKit.framework/FBAEMKit' does not contain 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.

Steps to reproduce

Just update the SDK version to the latest version and compile the project I am getting the error

Facebook SDKs for Signin

pod 'FBSDKCoreKit', '~> 15.0' pod 'FBSDKLoginKit', '~> 15.0' pod 'FBSDKShareKit', '~> 15.0'

Code samples & details

// INSERT YOUR CODE HERE
var example = "Example code"

pradipaub36 avatar Oct 21 '22 11:10 pradipaub36

Hi @pradipaub36 👋 I also encountered the same issue when archiving my Xcode project. In my case, I fixed the issue by adding the following lines to my Podfile to disable bitcode in all targets:

...
post_install do |installer|
  installer.pods_project.targets.each do |target|
    target.build_configurations.each do |config|
      config.build_settings['ENABLE_BITCODE'] = 'NO'
    end
  end
end

Also make sure to disable bitcode in your Xcode project build settings too: bitcode

I was initially sceptical as to whether this was a safe change to make so I did some further research. According to the Xcode 14 release notes

Xcode no longer builds bitcode by default and generates a warning message if a project explicitly enables bitcode: “Building with bitcode is deprecated. Please update your project and/or target settings to disable bitcode.” The capability to build with bitcode will be removed in a future Xcode release. IPAs that contain bitcode will have the bitcode stripped before being submitted to the App Store. Debug symbols for past bitcode submissions remain available for download. (86118779)

I am currently using Xcode 13.4.1 but it seems that bitcode has been officially deprecated by Apple and it is therefore safe to disable this flag.

bonesyblue avatar Oct 28 '22 07:10 bonesyblue

Disabling bitcode is not a solution, it's just a bypass of the problem. For iOS (iphones) you want to have it enabled for size optimization and crash reports.

Someone has any idea how to add a bitcode to this package?

radekzz avatar Nov 01 '22 09:11 radekzz

I'm having the same issue, setting 'ENABLE_BITCODE' to 'NO' didn't solve the problem. Xcode 13.2.1

Edit: updating to Xcode 14.1 resolved the issue.

rami965 avatar Nov 17 '22 11:11 rami965

Setting Enable Bitcode to NO in Xcode Build Settings resolved this for me. I didn't need to set it in the post_install in my Podfile.

I'm not an expert in native iOS (I'm a React Native developer) so I'm not really sure how this is going to affect my app.

zholmes1 avatar Nov 25 '22 14:11 zholmes1

if you disable bitcode, wont you not get dsyms generated for your app unless you are on xcode 14+ ?

mmdock avatar Dec 01 '22 22:12 mmdock

I’m getting treid of this Sent from my iPhoneOn Dec 1, 2022, at 2:09 PM, Morgan Dock @.***> wrote: if you disable bitcode, wont you not get dsyms generated for your app unless you are on xcode 14+ ?

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you are subscribed to this thread.Message ID: @.***>

jfostersn avatar Dec 02 '22 08:12 jfostersn

please update and help

hoanghuy0604 avatar Dec 17 '22 18:12 hoanghuy0604

please update and help

shivtaskeasy avatar Jan 03 '23 06:01 shivtaskeasy

@shivtaskeasy update Macos Ventura and Xcode to Version 14.2 (14C18) could help

hoanghuy0604 avatar Jan 04 '23 09:01 hoanghuy0604

It fails on Xcode Cloud CI. Could this lib be just shipped with Bitcode?

AndreyPoznyak avatar Feb 03 '23 23:02 AndreyPoznyak

Bitcode is deprecated starting with Xcode 14 (but basically Apple just says they're over with it in overall). Better drop your use of it wherever possible. 👍

username0x0a avatar Feb 27 '23 22:02 username0x0a