-
Notifications
You must be signed in to change notification settings - Fork 955
Add lldb to the tools list #1492
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
Conversation
This works in local testing on my macOS box. I did not know how to write a test case for this, so I could use some help here. |
Thanks for this! I'm a little hesitant to do this though as this is inserting a new |
I don't know, but I don't see why not for the command-line tool. I'm less certain about
rust-lldb is already taken. |
I tend to think installing an |
Hm ok, well in any case I would personally be pretty uncomfortable hijacking the locally installed We could tweak |
I'd like to take one last stab at convincing you that this is all ok. If you're still not convinced, I will look into the Here are the reasons I think it makes sense to make this link.
|
Some thoughts:
We might in the long-run want to install it by default, ideally we wouldn't mess with the names then
User's might have non-standard lldbs installed though, e.g., Swift's.
These seem like good reasons.
This seems like a pretty good solution to me. @tromey do you think re-using rust-lldb would work? If not, I think we should just install as lldb - it is optional to install, and if that is the best way forward we could keep it optional. |
@tromey ah yeah as @nrc mentioned I think we should plan for installing LLDB by default, and in that case it'd be in PATH by default and may override other LLDB installations. Also isn't ours "special" in that it doesn't do "the thing" with signing code on OSX, right? (does that mean it doesn't work for everything on OSX? or has that changed?) I agree that we should try to avoid the weird failure cases, but I think we can do that by always saying that users should execute I also sort of trust Swift to ship its own LLDB than us, they've got a lot more Apple people looking at it than we do :( |
The lldb build will pick up the xcode signed lldb-server rather than the unsigned one. Which is weird but has the side effect of making it work for us. As far as I can tell. Any opinions on what would be a good name for our lldb? I am not sure I am ready yet to remove the rust-lldb script and rename "lldb" to "rust-lldb". Instead in the interim I think I would prefer to make rust-lldb adaptive, assuming that's possible somehow.
They won't because stock lldb pretends that rust is c++ and will try to solider on. That is, with the current plan "lldb myprogram" will still do something, and a user may or may not notice until the debugger prints something incorrect. |
If we're not ready to take oer |
Ok, thanks. I'll come back around when the prerequisites are done. |
If we don't make a wrapper at all, perhaps we can just keep the name |
Yeah that sounds reasonable to me! |
We're shipping a rust-enabled lldb, but the "lldb" executable is not installed into the "bin" directory by rustup. See the discussion in rust-lang/rustup#1492 for background on this decision. There, we agreed to have rust-lldb prefer the rust-enabled lldb if it is installed. This patch changes dist.rs to put lldb into rustlib, following what was done for the other LLVM tools in rust-lang#53955, and then fixes rust-lldb to prefer that lldb, if it exists. See issue rust-lang#48168
…alexcrichton Have rust-lldb look for the rust-enabled lldb We're shipping a rust-enabled lldb, but the "lldb" executable is not installed into the "bin" directory by rustup. See the discussion in rust-lang/rustup#1492 for background on this decision. There, we agreed to have rust-lldb prefer the rust-enabled lldb if it is installed. This patch changes rust-lldb to look in the sysroot and use the lldb found there, if any. See issue rust-lang#48168
…alexcrichton Have rust-lldb look for the rust-enabled lldb We're shipping a rust-enabled lldb, but the "lldb" executable is not installed into the "bin" directory by rustup. See the discussion in rust-lang/rustup#1492 for background on this decision. There, we agreed to have rust-lldb prefer the rust-enabled lldb if it is installed. This patch changes rust-lldb to look in the sysroot and use the lldb found there, if any. See issue rust-lang#48168
…alexcrichton Have rust-lldb look for the rust-enabled lldb We're shipping a rust-enabled lldb, but the "lldb" executable is not installed into the "bin" directory by rustup. See the discussion in rust-lang/rustup#1492 for background on this decision. There, we agreed to have rust-lldb prefer the rust-enabled lldb if it is installed. This patch changes rust-lldb to look in the sysroot and use the lldb found there, if any. See issue rust-lang#48168
No description provided.