Is there a way to load dylib in debug environment?
dylib: file system sandbox blocked mmap()
Is there a way to load dylib in debug environment?
Can you expand on your requirements here? It is possible to load a dylib using
dlopen
on iOS, even in a production environment, as follows:
Wrap it in a framework.
Include that framework in your app’s Frameworks directory.
I presume that this doesn’t meet your requirements, in which case it’d be helpful if you explained those requirements in more detail.
Share and Enjoy
—
Quinn “The Eskimo!”
Apple Developer Relations, Developer Technical Support, Core OS/Hardware
let myEmail = "eskimo" + "1" + "@apple.com"
Thank you for reply.
I am trying a develop tool to hot reload changed code without rebuilding, that will download a dylib to document path and load it by "dlopen".
And simulator is ok.
I know it works if a put the dylib into app self. But now the dylib path is document, and it is blocked.
So...how should i do?
Thand you.
I am trying a develop tool to hot reload changed code without rebuilding
Doing this by loading a dylib on iOS isn’t feasible. The iOS sandbox prevents you from loading code in this way, even on development-signed processes (those with the
get-task-allow
entitlement).
About the only way forward I can see is to compile the code to LLVR IR and then interpret it.
Share and Enjoy
—
Quinn “The Eskimo!”
Apple Developer Relations, Developer Technical Support, Core OS/Hardware
let myEmail = "eskimo" + "1" + "@apple.com"
Thank you again.