JDevlieghere added a comment.

In D88866#2313371 <https://reviews.llvm.org/D88866#2313371>, @aprantl wrote:

> So this is adding a fallback that ignores DEVELOPER_DIR if it is set, but 
> doesn't exist? Is that really desirable, or am I misunderstanding the patch? 
> I would expect LLDB to fail hard if the DEVELOPER_DIR in the environment is 
> wrong and not silently ignore it...

It's slightly more subtle than that, it falls back to running `xcrun` without a 
developer dir if we couldn't find the desired SDK with the developer dir set. 
It doesn't mean the developer dir is invalid or doesn't exist, it just means we 
couldn't find the SDK there. Imagine for the sake of argument that you're 
running an Xcode that has no SDKs and that this Xcode is not `xcode-select`ed. 
Based on lldb's location in LLDB.framework it will do an `xcrun` with the 
developer set to the Xcode without any SDKs and that will fail. With this 
patch, when that happens, we'll fall back to trying the `xcode-select`ed by 
running `xcrun` without a developer dir specified. I know it sounds like a 
contrived example but that's exactly what I was running into...


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D88866/new/

https://reviews.llvm.org/D88866

_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to