-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Build universal iOS framework #54
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #54 +/- ##
=======================================
Coverage 20.82% 20.82%
=======================================
Files 10 10
Lines 317 317
Branches 50 50
=======================================
Hits 66 66
Misses 245 245
Partials 6 6
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
5cb3f3a
to
337493a
Compare
Most importantly, this exposes the native library as a "framework" in iOS so that a consuming iOS application will not be rejected by the App Store. In addition to this though, we combine both x64 and arm64 binaries into one *universal* binary, which should help make things "just work" whether in an emulator or a real device.
3e339f7
to
9217544
Compare
6bf5e39
to
6c1f008
Compare
This change mostly looks good. But we have one issue and one question: Issuehttps://github.com/AArnott/iOSSampleInteropApp is a minimum iOS app to test this change. It builds at runtime, and appears to copy the native as well as the managed libraries into the app when targeting the emulator. But the app crashes with a
Since the file layout is equivalent to that used by the Open questionIs laying out the nupkg such that the native Apple framework is under the The package layout as it stands now
|
5fa4125
to
c8a1730
Compare
Possibly relevant tip: xamarin/xamarin-macios#21238 |
9f10d9b
to
47b31ea
Compare
This leads to the Xamarin.iOS SDK automatically discovering the xcframework, which otherwise needs to be called out for inclusion using a `<NativeReference>` item pointing to the `runtimes\ios-universal\native\nerdbank_qrcodes.xcframework` directory with `Kind=Framework` metadata.
47b31ea
to
95bff41
Compare
Most importantly, this exposes the native library as a "framework" in iOS so that a consuming iOS application will not be rejected by the App Store.
In addition to this though, we combine both x64 and arm64 simulator binaries into one universal binary, which should help make things "just work" whether the simulator runs on an x64 or an arm64 (Apple Silicone) mac.