dSYM support for SE-0272 Package Manager Binary Dependencies

Hey @steipete, there isn't much out there this subject so I got here. I thought you'd be interested in the results of my investigations.

My goal was different : using binary as a compile cache (pretty much in the idea of Rome for Carthage), but allowing breakpoint debugging through compiled frameworks. This is possible when Xcode knows the debugging symbols of a binary and you share breakpoints across Xcode projects using "Move breakpoint to > User" (from your framework xcproj in that case).

I figured that you can actually embed the PSPDFKit.framework.dSYM without renaming it into PSPDFKit.xcframework/_matching_architecture_/PSPDFKit.framework.dSYM. (In my case I zip the whole thing, upload it and reference it as a binaryTarget for SPM and Xcode 12 beta)

Since your framework is compiled for release (optimised), when you start debugging from your app, you'll get PSPDFKit was compiled with optimization - stepping may behave oddly; variables may not be available.

I don't think it is annoying to have the dSYM along with each architecture in an xcframework since there's not a raw copy of the xcframework in the app bundle. On top of that your embedded-script wouldn't have to be given references to the dSYM files, it could just find them relatively.