iOS multiplatform setup
RdeWilde opened this issue · comments
Did you consider using this multiplatform approach for the iOS releases? Seems interesting, maybe it is a clean alternative.
https://www.raywenderlich.com/19611194-multiplatform-app-tutorial-swiftui-and-xcode-12
This is something that I'd definitely like to address at some point and also talked about it a bit in https://johnoreilly.dev/posts/swiftui-multiplatform-kotlin-multiplatform/. What's there right now, as you can imagine, evolved over time. I'll hopefully get chance at some point to address but if anyone wants to open a PR in meantime that's also very welcome!
I use that now in my newest project at work.
If you can't use Swift Packages here the essential trick is to build a XCFramework.
Kotlin Native is limited to only target one architecture per created framework. That's a problem for Swift Multiplatform of course because iOS and macOS have different archs.
But now you can combine them and all is good. It took me some time to figure that out.
Here is the solution: https://gist.github.com/epool/b55f9b8f64427efc5717510e0246c278
Latest version has single XCode project now.