[swift-users] Swift 4.0 LLDBFrontend Crash

Alex Blewitt alblue at apple.com
Mon Oct 16 13:00:25 CDT 2017


> On 16 Oct 2017, at 18:52, Edward Connell <ewconnell at gmail.com> wrote:
> 
> While creating a bug report for this problem I placed my simple repro case in a separate project with default build settings and I found that it no longer crashes LLDB.
> 
> My main project links to several system C libraries, because I am using libpng, Cuda, etc...
> In order for LLDB to function with my project and load things from the AST context, I was told to specify the clang include directory.
> 
> swift build -Xswiftc -I${SWIFT_HOME}/lib/swift/clang/include
> 
> In the past everything worked fine.
> 
> The stand alone bug repro project has no C library dependencies, however if I add this option, LLDB crashes.

If you can add that information to the bug report, including whawt version of swift you're using (with swiftc -v) and the crash report then that would allow others to see what problem you're experiencing. 

I assume that SWIFT_HOME is the same location as the swift executable that you're running? Might be worth checking with 'which swift'.

> I tried eliminating this option from my main project, and from a separate project using SwiftProtobuf. The result is that I am no longer able to debug either of them. Is there some new way we are supposed to pick up system imports, or is the a legitimate bug?

The Swift REPL on Linux needs to have the -I flag in order to work as expected. However, the swift compiler shouldn't need to have that information, since it will know where the corresponding include directory is.

Alex


More information about the swift-users mailing list