Skip to content

Activate swift build support for command plugins #8845

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

Merged
merged 12 commits into from
Jun 24, 2025

Conversation

cmcgee1024
Copy link
Member

@cmcgee1024 cmcgee1024 commented Jun 19, 2025

Be consistent in the detection of the build system settings so that both the
build system and the build parameters are using the same setting. Use the
build system setting given after the command plugin name as the highest
precedence, followed by the one (if any) provided after the package subcommand.

When building a specific target with the swiftbuild build system, set the configured
target in the build request to be the one that isn't a dynamic target.

Tag the TraitTest.packagePluginGetSymbolGraph_enablesAllTraits with a known
issue when using the swiftbuild build system since the symbol graph extraction
is not yet working there.

Add the toolchain's runtime environment to the environment used when running
command plugins so that the tools have the necessary runtime dependencies when
the plugin decides to run them on platforms like Linux.

@cmcgee1024
Copy link
Member Author

@swift-ci please test

Filter dynamic targets when discovering configured targets

Use the build plan and binary path for the native build system tool path calculation
@cmcgee1024
Copy link
Member Author

@swift-ci please test

Add runtime library environment to the command plugin invocation for the tools that it runs
@cmcgee1024
Copy link
Member Author

@swift-ci please test

Skip testCommandPluginTargetBuilds on Linux due to bug building fixture in release mode

Skip testCommandPluginSymbolGraphCallbacks until symbol graph callback is supported with swiftbuild
@cmcgee1024
Copy link
Member Author

@swift-ci please test

@cmcgee1024
Copy link
Member Author

@swift-ci please test

…scope

Skip test on autolink extract errors on non-macOS platforms
@cmcgee1024
Copy link
Member Author

@swift-ci please test

@cmcgee1024
Copy link
Member Author

@swift-ci please test

@cmcgee1024
Copy link
Member Author

@swift-ci please test

1 similar comment
@cmcgee1024
Copy link
Member Author

@swift-ci please test

@cmcgee1024
Copy link
Member Author

@swift-ci please test

@cmcgee1024
Copy link
Member Author

@swift-ci please test

@cmcgee1024 cmcgee1024 marked this pull request as ready for review June 24, 2025 15:19
@cmcgee1024
Copy link
Member Author

@swift-ci test Windows

@cmcgee1024
Copy link
Member Author

@swift-ci test macOS

@cmcgee1024 cmcgee1024 enabled auto-merge (squash) June 24, 2025 21:35
@cmcgee1024 cmcgee1024 merged commit a38e1d6 into swiftlang:main Jun 24, 2025
6 checks passed
xedin added a commit that referenced this pull request Jun 25, 2025
marcprux pushed a commit to swift-everywhere/swift-package-manager that referenced this pull request Jul 7, 2025
Be consistent in the detection of the build system settings so that both
the build system and the build parameters are using the same setting. Use
the build system setting given after the command plugin name as the highest
precedence, followed by the one (if any) provided after the package
subcommand.

When building a specific target with the swiftbuild build system, set
the configured target in the build request to be the one that isn't a
dynamic target.

Tag the `TraitTest.packagePluginGetSymbolGraph_enablesAllTraits` with a
known issue when using the swiftbuild build system since the symbol graph
extraction is not yet working there.

Add the toolchain's runtime environment to the environment used when
running command plugins so that the tools have the necessary runtime
dependencies when the plugin decides to run them on platforms like Linux.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants