libjpeg-turbo-builder icon indicating copy to clipboard operation
libjpeg-turbo-builder copied to clipboard

iOS 9 and Bitcode

Open fishandphil opened this issue 9 years ago • 9 comments

Hi dhoerl,

What's your solution for iOS 9 and the bitcode for app thinning?

Cheers Philippe

fishandphil avatar Sep 16 '15 09:09 fishandphil

I just contacted DRC. The plan is for me to figure out the appropriate shell command, and supply it to him (the command to build the bitcode file).

He won't be able to add it to the official build until version 1.5, so I guess I'll have to get this project working again using the latest code (and not my hacked up NEON revisioner).

Are you in any particular hurry?

dhoerl avatar Sep 16 '15 14:09 dhoerl

Thanks David!

I have disabled bitcode for now in our project. I believe that Google Analytics is not bitcode enabled yet either! So that's fine for this version. Will def need bitcode on libjpeg-turbo for our October release; Apple watch oblige :)

Will be keeping an eye on this repo. I don't think I have the skills to get the bitcode in myself; very far from my comfort zone!

Cheers Philippe

fishandphil avatar Sep 16 '15 14:09 fishandphil

Just give me a heads up - its going to take me a few hours to get the repo back into good shape.

dhoerl avatar Sep 16 '15 15:09 dhoerl

Hi David, Happy new year

I am wondering if you got your head around building the library with Bitcode? We are submitting a big update of our app on Thursday 14th to Apple and it would have been awesome en enable that feature.

Cheers Philippe

fishandphil avatar Jan 09 '16 10:01 fishandphil

I hadn't gotten around to it, but trying now. There is a new compile flag one must use - however the source is now on git, so much work to be done. Lets see how it goes - will update this later with progress report.

dhoerl avatar Jan 09 '16 16:01 dhoerl

Thank David We appreciate very much.

On Saturday, 9 January 2016, David Hoerl [email protected] wrote:

I hadn't gotten around to it, but trying now. There is a new compile flag one must use - however the source is now on git, so much work to be done. Lets see how it goes - will update this later with progress report.

— Reply to this email directly or view it on GitHub https://github.com/dhoerl/libjpeg-turbo-builder/issues/8#issuecomment-170257154 .

fishandphil avatar Jan 09 '16 19:01 fishandphil

The good news is that I have the project building again from the github source. It appears that all that is needed for libraries is an additional flag to get bitcode: '-fembed-bitcode'

However, when looking at the resultant library, the NEON files don't have bitcode sections (actually each .o has a bitcode section, just like it has a TEXT section).

I just posted a question on the internal apple forums - you can add yourself as a monitor. Once that gets answered we can hopefully proceed further. In the end, it should be possible to build the library from the original build script as documented in the build readme, by configuring additional CC and AS flags.

PS: this Stack OverFlow discussion was a big help on bitcode.

dhoerl avatar Jan 09 '16 20:01 dhoerl

Hi David, i configured the flags in script variable as below CFLAGS_ARMV7="-isysroot ${SDK_LOC} -Os ${FLAGS_ARMV7} -fembed-bitcode" CCASFLAGS_ARMV7="-no-integrated-as -fembed-bitcode"

but i get the below error

ld: './.libs/libjpeg.a(jsimd_arm_neon.o)' 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. for architecture armv7

can you please help me on this .

Regards, Chandan

chandanprakash avatar Jul 20 '16 12:07 chandanprakash

NEON code does not generate bitcode, so its impossible to get a bitcode architecture from it.

dhoerl avatar Jul 20 '16 15:07 dhoerl