Skip to content

Conversation

@artemcm
Copy link
Contributor

@artemcm artemcm commented May 13, 2024

Cherry-pick of #1601

Explanation: On failure to load libSwiftScan when Explicitly Built Modules are enabled, attempt to run a dependency scan by invoking swift-frontend -scan-dependencies ... on the shell and parsing out the JSON output.

Risk: Low. This change affects a code-path that is followed only in the event that the Swift toolchain is not configured with a correctly (as-expected) placed libSwiftScan or the event that there is a code-signing difference between the client process and the libSwiftScan it attempts to load. Previously, in these cases we encountered a hard failure. Now, we will try a best-effort fallback path attempt. Default code-path remains unaffected.

Testing: Test added to the automated test suite.

Reviewed By: @cachemeifyoucan, @owenv

Resolves rdar://127768140

…case libSwiftScan shared library cannot be loaded.

Resolves rdar://127768140
@artemcm artemcm requested a review from nkcsgexi May 13, 2024 18:33
@artemcm
Copy link
Contributor Author

artemcm commented May 13, 2024

@swift-ci test

Copy link
Contributor

@nkcsgexi nkcsgexi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@artemcm
Copy link
Contributor Author

artemcm commented May 13, 2024

@swift-ci test Windows platform

@artemcm artemcm merged commit e5f9a65 into swiftlang:release/6.0 May 14, 2024
@artemcm artemcm deleted the 60DepScanFallback branch May 14, 2024 20:58
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