How to enable only the framework when creating the device, and not iOS Simulator?

We used a third-party push notification structure, which was not compiled for x86_64, which means that whenever we create a simulator, we get a warning about the assembly. Since they tried to treat warnings as errors, this does not.

Id like to include this structure only when creating on devices. Then I only compile code that uses it on devices as well.

Is this achievable?

+4
source share
1 answer
  • Make the framework optionalnot requiredin the building phases> Link to binary files with libraries
  • > " " Debug Any SDK iOS Simulator -ObjC -weak_framework YourFrameworkName.
  • , #if TARGET_IPHONE_SIMULATOR.

enter image description here

+4

Source: https://habr.com/ru/post/1648504/


All Articles