How to use SwiftPM traits from Xcode?

Hello everyone,

We would like to have different build configurations beside Debug and Release and until now we use a complicated script that at build time sets all the Xcode build settings such that this works. This is because SPMs do not support other build configurations. Now I came across package traits which sound very close to what we need but they do not seem to be supported from within Xcode projects. At least not from what i have found.

Is there a way to enable and disable SPM traits from within an Xcode project?

Konstantin

2 Likes