How to link a swift package only under specific configurations?

Hi everyone,

My project is using SPM with the umbrella framework approach, which almost every frameworks and libraries are being added to another framework target, and the app target has that umbrella framework linked in order to use those libraries.

The problem I am encountering is that some of the frameworks being added are not permitted to be included when submitting the binary to AppStore, e.g. RxTest. In order to facilitate for automation I am currently thinking of adding the linker flag "-framework RxTest" in build settings' "other linker flag" of specific configurations like debug, but I am not sure what is the path to be put in the search path settings.

The libraries being checkout is in "SourcePackages/checkouts" and at the moment the path settings I've got is "$(BUILD_DIR)/../SourcePackages/checkouts" but seems it doesn't work, i.e. it gives the error "No such module RxTest".

Anyone knows is there any path parameter pointing towards the checked out source packages? Or is there any other viable ways to achieve the same results?

Thank you!