1

With bitcode, Apple say they can re-build my application on demand, whenever they think it is necessary.

If my source code contains preprocessor macros, when will those run? When I build and archive my IPA locally? Or also when Apple re-builds the app?

I'm considering both custom macros, as well as built-in ones such as __DATE__ and __TIME__. Which date/time will it get if Apple re-builds the app in the app store?

Nathan H
  • 48,033
  • 60
  • 165
  • 247

1 Answers1

0

No; Apple will have a 32 bit version and a 64 bit version for your app in bit code; that's all. All the #define's will be evaluated by your compiler and not be sent to Apple.

With what they have Apple can easily produce a new version of your app that will run on new versions of the ARM processor. They most likely could build a new version that would run on an Intel processor instead of an ARM processor (while their instruction set and implementation are very different, how these chips behave is actually very similar). Building a version for a little-endian PowerPC would be possible; a version for big-endian PowerPC would quite likely not work if your app includes code that needed to be different on a big-endian processor.

__DATE__ and __TIME__ would be the ones that were valid when you built the app.

The result of Apple building a new version for a new processor from bitcode should be exactly the same as if you had submitted the app with code for that processor. Obviously you don't have a compiler for ARM13 which will be introduced in 2022, but if Apple builds that version from your submitted bit code, it should be as if you had had that compiler today.

gnasher729
  • 51,477
  • 5
  • 75
  • 98
  • So you are saying the bitcode I upload to Apple will not contain my macros, rather they will contained the already generated values? Also, they have macros for detecting specific architectures (`__ARM_ARCH_7A__`, etc) so how would that work if it only really builds just 2 versions? – Nathan H Dec 01 '16 at 09:15