-
Notifications
You must be signed in to change notification settings - Fork 13.2k
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
Add gdb to the build #56990
Add gdb to the build #56990
Conversation
This optionally adds gdb to the Rust build, allowing gdb to be installed via rustup. This makes it simpler to make debuginfo changes, as gdb updates can now be shipped immediately. If gdb is not checked out, nothing changes. The build is perhaps a bit chatty, as gdb's "make" and "make install" are run each time, even if they do nothing. rust-gdb is modified to prefer the gdb installed by rustup. This is analogous to what was done for rust-lldb. The built gdb requires Python 2.7 as a shared library (other dependencies are statically linked). This is a least-common-denominator Python that is widely available and stable; dynamic linking is used to avoid breaking existing gdb Python code that might load shared libraries that themselves require a dynamic libpython. To avoid problems here, a small wrapper program is used that attemps to dlopen libpython; with failures being reported to the user in an intelligible way. Two of the Linux dist builds are updated to build gdb. More could be added if need be. If gdb is built as part of the build, and if no other gdb was specified in config.toml, then the just-built gdb will be used for debuginfo testing. Closes rust-lang#34457
(rust_highfive has picked a reviewer for you, use r? to override) |
|
Thanks for this! On the technical side this looks pretty reasonable to me. I'm somewhat hesitant to merge this though because I don't feel like it's tenable to keep adding large tools like this to our distribution. In the limit I don't think we are currently equipped via our current infrastructure to ship what's amounting to an entire toolchain distribution strategy (linker, debugger, compiler, libraries, tooling, etc). We're already feeling lots of pain on CI with timings, and although sccache can accelerate the build here it'll inevitably be yet more to build on builders already bleeding for time. I think the end goal here is great and we should move towards it, but I'm just not sure that we're ready for this just yet. I think we need to figure out a strategy that doesn't bottleneck absolutely everything on this one repository for distributing releases. Would you be up for postponing this until there's been a chance to chat more with the dev tools team as well as the infrastructure team? |
Sure. |
Ok! I'll put this on the infra team agenda to talk about, and @nrc you might be interested in this for the dev-tools agenda too! I'm gonna reopen this temporarily at least because I'd also like to use our try builds to analyze how long it takes to build gdb |
@bors: try |
Add gdb to the build This optionally adds gdb to the Rust build, allowing gdb to be installed via rustup. This makes it simpler to make debuginfo changes, as gdb updates can now be shipped immediately. If gdb is not checked out, nothing changes. The build is perhaps a bit chatty, as gdb's "make" and "make install" are run each time, even if they do nothing. rust-gdb is modified to prefer the gdb installed by rustup. This is analogous to what was done for rust-lldb. The built gdb requires Python 2.7 as a shared library (other dependencies are statically linked). This is a least-common-denominator Python that is widely available and stable; dynamic linking is used to avoid breaking existing gdb Python code that might load shared libraries that themselves require a dynamic libpython. To avoid problems here, a small wrapper program is used that attemps to dlopen libpython; with failures being reported to the user in an intelligible way. Two of the Linux dist builds are updated to build gdb. More could be added if need be. If gdb is built as part of the build, and if no other gdb was specified in config.toml, then the just-built gdb will be used for debuginfo testing. Closes #34457
💔 Test failed - status-travis |
The job Click to expand the log.
I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact |
@bors: retry |
⌛ Trying commit 5193d1f with merge 93824984a2222f91fff006829312e6bfab3d61c0... |
☀️ Test successful - status-travis |
Triage; @tromey Hello, have you been able to get back to this PR? |
@alexcrichton knows the state now, see #56990 (comment) |
er sorry I forgot to come back to this, but @tromey looking at the logs of the try build I'm not sure I even saw GDB get built? |
Yeah, me neither :(. I will look into it. |
Ping from triage @tromey: What is the status of this PR? |
I haven't looked at it yet. Maybe will not have time to, I suppose #56990 (comment) makes it seem not super worthwhile. |
ping from triage. @tromey closing this based on your comment above and inactiveness. If you want to pursue this in the future you can reopen it and will get it reviewed. Thanks for contributing! |
This optionally adds gdb to the Rust build, allowing gdb to be
installed via rustup. This makes it simpler to make debuginfo
changes, as gdb updates can now be shipped immediately.
If gdb is not checked out, nothing changes.
The build is perhaps a bit chatty, as gdb's "make" and "make install"
are run each time, even if they do nothing.
rust-gdb is modified to prefer the gdb installed by rustup. This is
analogous to what was done for rust-lldb.
The built gdb requires Python 2.7 as a shared library (other
dependencies are statically linked). This is a
least-common-denominator Python that is widely available and stable;
dynamic linking is used to avoid breaking existing gdb Python code
that might load shared libraries that themselves require a dynamic
libpython. To avoid problems here, a small wrapper program is used
that attemps to dlopen libpython; with failures being reported to the
user in an intelligible way.
Two of the Linux dist builds are updated to build gdb. More could be
added if need be.
If gdb is built as part of the build, and if no other gdb was
specified in config.toml, then the just-built gdb will be used for
debuginfo testing.
Closes #34457