As is known to everyone, static libraries can work well in an Iphone App and your App can be easily approved by IOS App Store
Unfortunately, the two static libraries I'm using now have the some C functions and variables.
so I compiled them into *.dylib (dynamic libraries), and copy them to "Bundle Resources" in XCode.
dylib_handle = dlopen(dylib_path_in_resource_bundle, RTLD_LAZY);
func = dlsym(dylib_handle, "func");
// invoke func();
This works well in simulator and Ipad (of course, different dynamic libraries).
I noticed that somebody said Iphone app does not support any third party dynamic libraries and my app will be rejected. (see here)
but I carefully read the "App Store Review Guidelines", I found no item meet my question.
I'm confused now!
Does iphone app support dynamic libraries? Does IOS AppStore allow this?
Who can give me an official response.
As Bernardo Ramos states in a comment: "Since iOS8 we can use dynamic libraries".
Dynamic libraries are not allowed by the App Store. No code may be loaded at run-time. The answer is to convert them to static libraries and compile them into the application.
From iPhoneOSTechOverview:
"If you want to integrate code from a framework or dynamic library into your application, you should link that code statically into your application’s executable file when building your project."
Read "should" as "must"
See SO Answer: Can create dynamic library for iOS?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With