CocoaPods 1.9.3.beta.x added support for XCFrameworks (see https://github.com/CocoaPods/CocoaPods/issues/9148 and https://github.com/CocoaPods/CocoaPods/pull/9334). However, dSYMs are not currently supported.
At PSPDFKit, we currently bundle the CocoaPods artifact as the old fat .frameworks, and we plan on distributing XCFrameworks as soon as CocoaPods supports dSYMs in its latest stable version, as dSYM support is crucial for our customers.
You can manually integrate XCFrameworks into your project and add the dSYMs using an .xcfilelist, as described in the second step of this guide here: https://pspdfkit.com/guides/ios/current/getting-started/integrating-pspdfkit/#integrating-the-xcframework
PSPDFKit.xcframework, PSPDFKitUI.xcframework, PSPDFKit-dSYMs, and PSPDFKitUI-dSYMs in a writable location.strip-bitcode.sh and strip-framework.sh from PSPDFKit.xcframework/*/PSPDFKit.framework:rm PSPDFKit.xcframework/*/PSPDFKit.framework/strip-*.sh
PSPDFKit-dSYMs and PSPDFKitUI-dSYMs foldersto PSPDFKit.dSYMs, and PSPDFKitUI.dSYMs respectively..zip file) by compressing PSPDFKit.xcframework, PSPDFKitUI.xcframework, PSPDFKit.dSYMs, and PSPDFKitUI.dSYMs into PSPDFKit.zip.Archive.zip to PSPDFKit.zip.sudo gem install cocoapods --pre. In my tests, I used 1.9.3.beta.3 in my testscd into the project directory: cd CocoaPods-dSYM-Support/SwiftExamplePSPDFKit.zip) in the root folder (CocoaPods-dSYM-Support).pod install.open SwiftExample/SwiftExample.xcworkspace.
.frameworks.@amorde didnt we add dSYM support for xcframeworks in 1.9.x?
Hi @radazzouz 👋
dSYM support was added by including a folder in the format FrameworkName.dSYMs, so in this case if the folders PSPDFKit.dSYMs and PSPDFKitUI.dSYMs exist, CocoaPods should pick those up and include it during the build. Did you try that and, if so, did it not work correctly?
Thanks for the prompt response, @amorde! 👍
I just tested with the dSYM folders named PSPDFKit.dSYMs, and PSPDFKitUI.dSYMs instead of PSPDFKit-dSYMs and PSPDFKitUI-dSYMs and they dSYMS are still not present in the archive.
I also updated the instructions and the sample project's Podspec from the main comment so you can conveniently test it on your side.
BTW, when using the manual integration (see the Manual-Integration-dSYM-Support.zip sample project), the dSYMs can be found in the archive on both iOS and Mac Catalyst:
| iOS | Mac Catalyst |
| --- | --- |
|
|
|
Hmm ok will need some time to look into this, thanks for the detailed report!
The names of the dSYMs are messing with the logic of finding the binary inside the dSYM bundle.
This is something we can fix, hopefully I'll have a PR up soon in time for 1.9. Thanks for the report!
@radazzouz I've pushed up a WIP fix for this on the amorde/xcframework-dsyms branch - if you get the chance, check it out and let me know if it works for you. I tested it against PSPDFKit and it worked for me.
Thanks @amorde! 👍
I just pulled your branch and it did not work for me. Did you use the same sample project and the updated integration steps from the main comment?
Yes I did, thanks so much for the sample + detailed instructions!
What happened when you tried my branch? did it you see "Selected dsym [path]" in the build output?
What happened when you tried my branch?
Everything worked except for the dSYMs.Just like on 1.9.0.beta.3.
BTW, I used these instructions to build locally.
did it you see "Selected dsym [path]" in the build output?
No. Unfortunately, I did not.
Looks like I had some local changes that didn't get included in that commit - I pushed again, please give it another try when you can
Thank you so much, @amorde!
I confirm that it now works on both iOS and Mac Catalyst! 🎉
| iOS | Mac Catalyst |
| --- | --- |
|
|
|
Will ship with final 1.9.0 release.
Most helpful comment
Will ship with final 1.9.0 release.