Open eljobe opened 7 years ago
@lptr I think you might want to subscribe to this issue.
Everyone, it seems like Bazel is struggling with this same problem for C++ builds with clang: https://github.com/bazelbuild/bazel/issues/1000#issuecomment-285332074
There is an issue on the swift issue tracker here: https://bugs.swift.org/browse/SR-5694
It looks like we might not be able to solve this in any short order. I'm particularly interested in the general claim that using relative paths would break the lldb
debugger. It's also interesting that the bazel team is talking about post-processing the compiler outputs just prior to caching to rewrite the paths.
Oh, and the conversation has moved from the swift-evolution
mailing list to the swift-dev
mailing list. Seems like that's where the action is.
https://lists.swift.org/pipermail/swift-dev/Week-of-Mon-20170911/005325.html
swiftc
emits some absolute paths in to the.swiftmodule
files for executables it builds in bothdebug
andrelease
configurations.For the full story on why this causes us problems when considering caching these outputs, read this email thread on the swift-evolution mailing list.
We need to answer two main questions:
swiftc
compiler generate relative paths instead?So, far the only hopeful thing we've found is: https://github.com/apple/swift/blob/6607ff73ce7a039fe76e45e5870f21ce6b524f60/lib/Frontend/CompilerInvocation.cpp#L1178-L1179