I am modularizing an iOS app and stumbled across the same use case.
Maybe I think in the wrong direction.
I can provide two binary library product xcframework s in SPM:
one in Debug configuration with debug symbols: "LibADebugBin.xcframework"
one in Release configuration without debug symbols; "LibABin.xcframework"
Then I have to conditinally link "LibADebugBin.xcframework" and "LibABin.xcframework" depending on the configuration in the XCode app project.
I'm not sure there's a way to do it in SPM. I've been searching for a way to achieve this even without SPM and embedding directly in the Xcode project, and couldn't find a solid way to do it.
@antranapp Are you able to achieve this without SPM?
My case is I have two xcframeworks once called ABC.xcframework and one called ABC-release.xcframework and I want to link them conditionally based on build configuration.