How do I trust a swift macro target for Xcode Cloud builds?

1.2k Views Asked by At

I just added my first Xcode 15, Swift 5.9 macro from an open source package that I'm referencing via Swift Package Manager. The first time I compiled locally, I had to trust the macro's package via a dialog box, which is fine for a local build. However, now my app doesn't build on Xcode Cloud, with the error "Target must be enabled before it can be used."

How do I tell Xcode Cloud to trust the macro's target?

1

There are 1 best solutions below

1
slavikus On BEST ANSWER

I ran into same problem, and quickly discovered an additional defaults key that bypasses macro validation (same as -skipMacroValidation xcodebuild command line option):

defaults write com.apple.dt.Xcode IDESkipMacroFingerprintValidation -bool YES