Using nucleos within an KMP application submitted to the apple app-store and how to deal with the dylib signing #624
|
What is the plan with nucleus and submitting an app to the appstore that needs
Point 1: I can build nucleus under arm64 and x64 and than extract the dylib from the jar, thant create a new dylib via lipo ot have a universal library. How is nucleus than loading the library, should the library be name - should it be a -arm64 / -x86 as both being universal (simple to kmps skiko) or can we just use a single dylib? Point 2: Any help would be appreciated. |
Replies: 6 comments 1 reply
|
Isn't that question made obsolete by the fact that x86 has reached its end of life? |
|
Not yet, apps are still required to be universal (i think final EOL is 2027?) But besides that, signing is an issue nevertheless. But as far as i can see, the Nucleus load does first search in |
|
I actually meant the EOL of Compose on Intel Macs. See: https://kotlinlang.org/docs/multiplatform/compose-compatibility-and-versioning.html and the signing is done by nucleus. Pure ARM apps are allowed in the app-store if you set the minimum system version to 12. |
|
Please let us not drag this discussion if universal is still needed or not and how to circumvent it - it wis not relevant to this issuea as an essential facto Even though i have put
into my lib folder and thus java.library.path the dylibs are till loaded from the jar: I expected that with https://github.com/NucleusFramework/Nucleus/blob/main/plugin-build/plugin/src/sandboxShim/java/dev/nucleusframework/sandbox/NucleusSandboxLoader.java this is the way this should be implemented Any hints on that? |
|
Have you ever tried to just let Nucleus do its job without fiddling with the libraries yourself? The process is described for the CI/CD pipeline very well here: https://nucleusframework.dev/en/docs/packaging/ci-cd/ |
|
In the end, the current way Nucleus uses to ship native libraries will not work for the Apple App Store in any way. The reason is, that dylibs that are bundled within a jar need to be unpacked to a non-bundle folder during runtime. This happens automatically. Loading them from that folder, even if those are signed dylibs, is not allowed, and the apple appstore sandbox will fail. To fix this, you need to
|
In the end, the current way Nucleus uses to ship native libraries will not work for the Apple App Store in any way.
The reason is, that dylibs that are bundled within a jar need to be unpacked to a non-bundle folder during runtime. This happens automatically. Loading them from that folder, even if those are signed dylibs, is not allowed, and the apple appstore sandbox will fail.
To fix this, you need to