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鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dynamic frameworks should be stripped (STRIP_INSTALLED_PRODUCT) #10277
Comments
|
Has anyone found a good solution for this? We are hitting a similar issue around binary size for dynamic frameworks. However, when I explicitly change the stripping settings via the main app's Podfile (enabling "COPY_PHASE_STRIP" and "STRIP_INSTALLED_PRODUCT"), I run into the problem that the Swift symbols are mangled, so debugging becomes significantly harder. |
zacwest
added a commit
to home-assistant/iOS
that referenced
this issue
Oct 20, 2022
## Summary Cocoapods does not strip the .frameworks it creates, which was done for us automatically when we were submitting using Bitcode, but upgrading to Xcode 14 means that no longer happens for us. ## Any other notes I think the tides are shifting strongly towards moving back to SPM, which hopefully (lol) would be less buggy than the last time we tried it. Outstanding Cocoapods issue for this one: CocoaPods/CocoaPods#10277
|
Same issue |
1 task
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Report
A very old change, #1217, turned off the
STRIP_INSTALLED_PRODUCTbuild setting to ensure that internal symbols from static libraries properly end up in the dSYMs created by the Archive action. However, this doesn't make sense for dynamic libraries, which have separate dSYMs from the resulting app. Not stripping internal symbols can result in a huge increase in binary size for Swift, which has long symbol names and many internal symbols. (Objective-C tends to produce public andstaticsymbols but not internal (visibility(hidden)) in default Xcode configurations.)For a concrete example, a release arm64 build of SignalServiceKit is 27MB by default, and 18MB after stripping. 馃槶
#1217 also mentions that only the project-level setting is respected, not per-target settings. That was probably true in the past, but is no longer true in Xcode 12.1. I don't know when this changed, but it does mean the default behavior can be kept as is while turning stripping back on at the per-target level if the build product is a dynamic framework. (CocoaPods doesn't support non-vendored dynamic library pods, right?)
CocoaPods Environment
Stack
Installation Source
Plugins
Podfile
The text was updated successfully, but these errors were encountered: