Dynamic framework working with ios 7

234 Views Asked by At

I am building an ios framework which is flawlessly working for apps deployed ios 8 and above. But then i was facing a situation where i need to integrate my framework with an application which supports ios 7 as well. I searched and came to know that "Embedded Frameworks" are supported on versions ios 8 or above. Please note that Embedded Frameworks are "Dynamic Frameworks"

Also, I came to know that "Static Frameworks" can be integrated with ios7. Still it did not solved my problem. After trying really hard, my "Dynamic framework" suddenly worked in an app with Deployment Target set as ios 7!.

I started digging my code to check why it worked. Then i realised the steps i took to make the framework.

  1. I clicked on my project root & went to Build Settings and searched for machO Linker,therefore i changed the library from "Dynamic Library" to "Static Library".
  2. I build the project for "Generic iOS Devices" then for "iPhone Simulator" and finally made a universal framework using a script.

  3. I tried the static framework but i do not why, it did not work with my test project. There was some error that the class was not loaded. and even after loading the class somehow, other functionalities didn't work.

  4. I repeated the above two steps(1,2) again, but changed the macho Linker back to "Dynamic Library".

Bam! the framework worked!. The reason i think is, somehow i merged both static and dynamic Libraries?

The only problem with me right now is, i cannot check that my framework will be accepted by the Apple store or not.

I appreciate if anyone can enlighten me, I am really confused and need help.

0

There are 0 best solutions below