Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[New Output] Macro Target must be enabled before it can be used #341

Open
aksh1t opened this issue Dec 12, 2024 · 0 comments
Open

[New Output] Macro Target must be enabled before it can be used #341

aksh1t opened this issue Dec 12, 2024 · 0 comments

Comments

@aksh1t
Copy link

aksh1t commented Dec 12, 2024

What's the uncaptured output?

For Swift package targets containing macros, if they have not been enabled, xcodebuild gives this error when computing the target dependency graph:

...
/Users/runner/Library/Developer/Xcode/DerivedData/DeveloperAutomation-ayrroxrhfzoyoxdehmcuuwlcbuqz/SourcePackages/checkouts/Swallow/Package.swift:PACKAGE-TARGET:SwallowMacros: error: Target 'SwallowMacros' must be enabled before it can be used.
...

This error is suppressed by xcbeautify so it is not obvious at all why the build failed.

Suggested Regex

"must be enabled before it can be used" seems like a stable string to match for.

Suggested Output

No response

Additional Context

To test this, perform the following steps:

  1. Create a new macOS project called Test.
  2. Add the following repository as a package dependency: Swallow.
  3. Run the following command to prevent skipping macro validation:
defaults write com.apple.dt.Xcode IDESkipMacroFingerprintValidation -bool NO
  1. Run xcodebuild build -scheme Test.
@aksh1t aksh1t changed the title [New Output] [New Output] Macro Target must be enabled before it can be used Dec 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant