Conditionally including a library for different iOS SDK versions?

后端 未结 2 1426
孤城傲影
孤城傲影 2020-12-30 15:44

I\'m sure this has got a simple answer, but it\'s stumping me :(

I\'m trying to build an app that will run on iOS versions 4.3 and 5.0. I\'m fine with the idea of c

相关标签:
2条回答
  • 2020-12-30 16:06

    In your Target -> Build Settings, search for Other Linker Flags and click on the type of release (Debug or Release) and then on the bottom right, click Add Build Setting -> Add Conditional Setting and that will give you the SDK popup and the ability to specify any additional flags.

    0 讨论(0)
  • 2020-12-30 16:20

    You should also link the framework with the flag "Optional". You can set this at the "Build Phases" panel at the point "Link Binary With Libraries".

    see the image , you can switch "Required" to "Optional"

    you can switch "Required" to "Optional"

    0 讨论(0)
提交回复
热议问题