I have seen many reference Link for find out connection between the BITCODE_ENABLE
and .dylib
framework, But i can not get positive result. Please anyone help me what is the exact connection between both and also mention use of BITCODE_ENABLE
Clearly.
I think you're confusing what Bitcode actually is. Bitcode can be used with both static frameworks and dynamic libraries.
From the Apple docs:
Bitcode is an intermediate representation of a compiled program. Apps you upload to iTunes Connect that contain bitcode will be compiled and linked on the App Store. Including bitcode will allow Apple to re-optimize your app binary in the future without the need to submit a new version of your app to the store.
Most libraries and frameworks are "fat," meaning they contain extra binaries to support all architectures. This means that an iOS framework might support armv7, armv7s, and i386 (all device architectures and the simulator).
Building a library with bitcode allows it to support App Thinning. Meaning only the binaries appropriate for the architecture the app will run on are downloaded from the App Store. Additionally as Crazyrems mentions in the comments, this will optimize the app installation and download size, as the device will only download the assets necessary for the application to run on that specific architecture/device.
I won't go into details about LLVM IR, but I would recommend reading these articles for reference:
Bitcode Demystified
Why I’m not enabling Bitcode - Thoughts on application binaries packaging and software distribution
Static Libraries, Frameworks, and Bitcode
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With