Skip to content

[lldb] Add non-Apple implementation of GetSDKPathFromDebugInfo #8974

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
Jul 12, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion lldb/source/Plugins/TypeSystem/Swift/SwiftASTContext.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1937,7 +1937,9 @@ static std::string GetSDKPath(std::string m_description, XcodeSDK sdk) {
/// Force parsing of the CUs to extract the SDK info.
static std::string GetSDKPathFromDebugInfo(std::string m_description,
Module &module) {

#if !defined(__APPLE__)
return {};
#else
auto sdk_or_err = PlatformDarwin::GetSDKPathFromDebugInfo(module);
if (!sdk_or_err) {
Debugger::ReportError("Error while parsing SDK path from debug-info: " +
Expand All @@ -1954,6 +1956,7 @@ static std::string GetSDKPathFromDebugInfo(std::string m_description,
module.GetFileSpec().GetFilename().GetCString());

return GetSDKPath(m_description, std::move(sdk));
#endif
}

static std::vector<llvm::StringRef>
Expand Down