Is it possible to determine how the app was built?
Is there any way to determine in code whether the app currently running is a developer, ad-hoc, or app sto开发者_开发问答re build?
You could add C preprocessor definitions for each type to your build configuration, and use that definition to set a variable or flag in executable code.
Debug builds can be sometimes be detected by calling a benchmark loop whose run time varies significantly between -O0 and -Os optimization levels on a known device model.
Apple is reported to change an app's Info.plist in App store distributions, so you could count and checksum the plist items.
精彩评论