klarna / klarna-mobile-sdk

Klarna Mobile SDK for iOS
https://docs.klarna.com/mobile-sdk/ios/
Apache License 2.0
29 stars 12 forks source link

Provide binary framework as XCFramework #56

Closed d4nielRV closed 4 years ago

d4nielRV commented 4 years ago
name about title labels assignees
Provide binary framework as XCFramework Improving the way the apps integrate the SDK  Provide binary framework as XCFramework    

Is your feature request related to a problem? Please describe. Klarna mobile SDK are currently providing multiple folders depending on the version of Xcode and fat/slim options for different architectures. In big development teams where not everybody has the same version of Xcode on occasions it's a problem. Moreover, in case you need to debug on Simulator, the fat version is need while for uploading to the App Store you need to take the slim one.

Describe the solution you'd like Providing the SDK as XCFramework would fix all those problems I mentioned above. https://developer.apple.com/videos/play/wwdc2019/416/

For example, during these days some of the developers in my team already use Xcode 12 so they need the version 2.0.22 you just released on Friday but our CI environment cannot be migrated yet. Using a xcframework would let us to have a unique dependency and let Xcode to take the corresponding binary.

We're using v2.0.21 and thinking in adopt v2.0.22

JonathanDowning commented 4 years ago

This would have a side benefit of being able to adopt Swift Package Manager. I would be strongly in favor of this proposal.

polar133 commented 4 years ago

Hi @d4nielRV and @JonathanDowning. In the latest version (2.0.26) we have our SDK in XCFramework and also as SPM. We still need to update our documentation but you can give a try just by adding this repo as a package dependency. Please, give a try and let us know how did it went.

bobergj commented 4 years ago

We still need to update our documentation but you can give a try just by adding this repo as a package dependency. Please, give a try and let us know how did it went.

It went kind of fine. But since all framework variants are in the same repo, the swift package download is ~700mb instead of just the ~30mb of the xcframework. Perhaps you can create a separate repository for the Swift package?