You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Swift version 5.3-dev (LLVM 6c69ba3, Swift af7ca0f3470a466)
Target: x86_64-unknown-linux-gnu
Additional Detail from JIRA
Votes
0
Component/s
LLDB for Swift
Labels
Bug
Assignee
None
Priority
Medium
md5: 3c0a257d2c62ccc4156ca7a708e09c29
Issue Description:
Attempting to debug an app using a system library (pipewire in this case) fails as LLDB cannot locate the library headers:
lldbSwiftASTContext("Tsunami")::CreateInstance(Module)
lldbSwiftASTContext("Tsunami")::SetTriple("x86_64-unknown-linux-gnu") settingto"x86_64-unknown-linux-gnu"lldbSwiftASTContext("Tsunami")::SetTriple("x86_64-unknown-linux-gnu") settingto"x86_64-unknown-linux-gnu"lldbSwiftASTContext("Tsunami")::DeserializeAllCompilerFlags() -- Found1ASTfiledataentries.
lldbSwiftASTContext("Tsunami")::DeserializeAllCompilerFlags() -- SDKpathfrommodule"ArgumentParser"was"".
lldbSwiftASTContext("Tsunami")::DeserializeAllCompilerFlags() -- SDKpathfrommodule"Earthquake"was "".lldb SwiftASTContext("Tsunami")::DeserializeAllCompilerFlags() -- SDK path from module "HeliumLogger" was "".lldb SwiftASTContext("Tsunami")::DeserializeAllCompilerFlags() -- SDK path from module "LoggerAPI" was "".lldb SwiftASTContext("Tsunami")::DeserializeAllCompilerFlags() -- SDK path from module "Logging" was "".lldb SwiftASTContext("Tsunami")::DeserializeAllCompilerFlags() -- SDK path from module "Propellor" was "".lldb SwiftASTContext("Tsunami")::DeserializeAllCompilerFlags() -- SDK path from module "Signals" was "".lldb SwiftASTContext("Tsunami")::DeserializeAllCompilerFlags() -- SDK path from module "Tsunami" was "".lldb SwiftASTContext("Tsunami")::DeserializeAllCompilerFlags() -- Picking SDK path "".lldb SwiftASTContext("Tsunami")::CreateInstance() -- Found serialized triple x86_64-unknown-linux-gnu.lldb SwiftASTContext("Tsunami")::SetTriple("x86_64-unknown-linux-gnu") setting to "x86_64-unknown-linux-gnu"lldb SwiftASTContext("Tsunami")::CreateInstance() -- No serialized SDK path.lldb SwiftASTContext("Tsunami")::CreateInstance() -- Host SDK path is .lldb SwiftASTContext::GetResourceDir() -- trying ePathTypeSwiftDir: /home/ryan/Projects/Develop/swift-toolchain/usr/lib/swiftlldb SwiftASTContext::GetResourceDir() -- found Swift resource dir via ePathTypeSwiftDir': /home/ryan/Projects/Develop/swift-toolchain/usr/lib/swiftlldb SwiftASTContext("Tsunami")::GetASTContext() -- Using Clang module cache path: /home/ryan/.cache/clang/ModuleCachelldb SwiftASTContext("Tsunami")::GetASTContext() -- Using prebuilt Swift module cache path: /home/ryan/Projects/Develop/swift-toolchain/usr/lib/swift/linux/prebuilt-moduleslldb SwiftASTContext("Tsunami")::GetModule("ArgumentParser")lldb SwiftASTContext("Tsunami")::GetModule("ArgumentParser") -- found ArgumentParserlldb SwiftASTContext("Tsunami")::GetModule("Earthquake")lldb SwiftASTContext("Tsunami")::GetModule("Earthquake") -- <module-includes>:1:10: note: in file included from <module-includes>:1:#include "include/cpipewire.h"
^error: /home/ryan/Projects/Develop/Tsunami/Sources/CPipewire/include/cpipewire.h:1:10: error: 'spa/param/audio/format-utils.h' file not found
#include <spa/param/audio/format-utils.h>
^error: could not build C module 'CPipewire'
Can be worked around by setting a custom compiler flag in ~/.lldbinit as follows:
Sorry, this took a wee while. It's a stripped version of my project. interestingly optimising the Pipewire module any further (reducing the complexity to a single PipewireOutput class in this example) resulted in the bug not being reduced.
Tested on Fedora 33 Beta with pipewire-devel installed, should be able to be tested on Fedora 32 as it will have the relevant package also. Have not tested on Ubuntu.
Environment
Fedora 33 Beta
Swift version 5.3-dev (LLVM 6c69ba3, Swift af7ca0f3470a466)
Target: x86_64-unknown-linux-gnu
Additional Detail from JIRA
md5: 3c0a257d2c62ccc4156ca7a708e09c29
Issue Description:
Attempting to debug an app using a system library (pipewire in this case) fails as LLDB cannot locate the library headers:
Can be worked around by setting a custom compiler flag in ~/.lldbinit as follows:
Similar symptoms to https://bugs.swift.org/browse/SR-12050 but involving system library rather than SwiftPM packaged module.
The text was updated successfully, but these errors were encountered: