Thin iOS app frameworks to the target architecture#7913
Thin iOS app frameworks to the target architecture#7913cbracken merged 3 commits intoflutter:masterfrom
Conversation
chinmaygarde
left a comment
There was a problem hiding this comment.
lgtm. There is no sense in doing this is in non-release modes. It will just add to the time it takes to launch the application for development/debugging. Also, I would write it in Dart instead of shell.
When building against frameworks that are distributed as multi-architecture fat binaries, we want to strip the frameworks we distribute down to only the architectures specified in $ARCHS. This patch adds: * The ability to specify commands to xcode_backend.sh (if none is specified, run BuildApp for backward compatibility). * A 'thin' command that invokes lipo to thin down the distributed as described above.
Invokes xcode_backend.sh thin on the build application.
Flutter does not yet support armv7 iOS devices. Limit the $ARCHS build variable to arm64 until then.
c641af2 to
388280f
Compare
|
Rewritten from scratch with some additional error checking and lipo -info output in the case where an architecture isn't present.
Is there a foolproof way of detecting release vs non-release builds? |
|
Fixes #7908. |
|
lgtm. I guess if it is fast enough, it doesn't matter. |
|
sgtm. I've got a followup that rewrites all the That work still needs a bit of performance tuning; the runtime is ~1.2s vs 0.4s for the shell version. Will take a look at whether snapshotting helps significantly and if so, we can do what we do with the |
|
I may be reading incorrectly but wouldn't this cause issues with armv7 users if we declare support for standard architectures but stripped out armv7 from libraries? |
|
Part of this patch was to change the |
|
Ah, understood |
No description provided.