Skip to content

[SourceKit] Pass 'swiftc' path to Driver when creating frontend args #65068

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 1 commit into from
Apr 13, 2023

Conversation

rintaro
Copy link
Member

@rintaro rintaro commented Apr 11, 2023

Driver uses its path to derive the plugin paths (i.e. 'lib/swift/host/plugins' et al.) Previously it was a constant string 'swiftc' that caused SourceKit failed to find dylib plugins in the toolchain. Since 'SwiftLangSupport' knows the swift-frontend path, use it, but replacing the filename with 'swiftc', to derive the plugin paths.

rdar://107849796

@rintaro rintaro force-pushed the sourcekit-pluginpath-rdar107849796 branch 2 times, most recently from 5d8c849 to 84778ee Compare April 11, 2023 17:20
@rintaro
Copy link
Member Author

rintaro commented Apr 11, 2023

@swift-ci Please smoke test

@rintaro rintaro force-pushed the sourcekit-pluginpath-rdar107849796 branch from 84778ee to 7797d96 Compare April 11, 2023 17:31
@rintaro
Copy link
Member Author

rintaro commented Apr 11, 2023

@swift-ci Please test

@rintaro rintaro force-pushed the sourcekit-pluginpath-rdar107849796 branch from 7797d96 to bbe1ae3 Compare April 11, 2023 17:48
@rintaro
Copy link
Member Author

rintaro commented Apr 11, 2023

@swift-ci Please test

@rintaro rintaro marked this pull request as ready for review April 11, 2023 20:55
@rintaro rintaro changed the title [WIP][SourceKit] Pass 'swiftc' path to Driver when creating frontend args [SourceKit] Pass 'swiftc' path to Driver when creating frontend args Apr 11, 2023
@rintaro
Copy link
Member Author

rintaro commented Apr 11, 2023

@swift-ci Please test

llvm::outs() << "Frontend Arguments END\n";
return CI.parseArgs(FrontendArgs, Diags);
}, ForceNoOutputs);
MainExecutablePath, Args, Diags,
Copy link
Member Author

Choose a reason for hiding this comment

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

MainExecutablePath is a path to swift-ide-test So it's not really correct. But it is enough for getSingleFrontendInvocationFromDriverArguments

@rintaro rintaro force-pushed the sourcekit-pluginpath-rdar107849796 branch from bbe1ae3 to e42ce7d Compare April 12, 2023 03:37
@rintaro
Copy link
Member Author

rintaro commented Apr 12, 2023

@swift-ci Please test

@rintaro
Copy link
Member Author

rintaro commented Apr 12, 2023

swiftlang/llvm-project#6633
@swift-ci Please smoke test

Driver uses its path to derive the plugin paths (i.e.
'lib/swift/host/plugins' et al.) Previously it was a constant string
'swiftc' that caused SourceKit failed to find dylib plugins in the
toolchain. Since 'SwiftLangSupport' knows the swift-frontend path,
use it, but replacing the filename with 'swiftc', to derive the plugin
paths.

rdar://107849796
@rintaro rintaro force-pushed the sourcekit-pluginpath-rdar107849796 branch from e42ce7d to 3517db4 Compare April 12, 2023 16:53
@rintaro
Copy link
Member Author

rintaro commented Apr 12, 2023

@swift-ci Please test

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