-
Notifications
You must be signed in to change notification settings - Fork 50
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
dev-lang/rust: Drop our custom package (1.80.0) in favour of upstream Gentoo's (1.80.1) #2237
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
We have previously avoided this package because its /etc/lsb-release clashes with the symlink created by our sys-apps/baselayout. This has led to the need to fork some packages, such as dev-lang/rust, just to avoid the dependency. Instead, we can just stop it from installing /etc/lsb-release with INSTALL_MASK. I also considered having it create the symlink instead of baselayout, but baselayout has the tmpfiles.d handling, so this is simpler. Signed-off-by: James Le Cuirot <jlecuirot@microsoft.com>
chewi
force-pushed
the
chewi/gentoo-rust
branch
from
August 15, 2024 12:52
02725ad
to
3bf7931
Compare
This would supersede #2229. |
Build action triggered: https://github.com/flatcar/scripts/actions/runs/10404098312 |
krnowak
reviewed
Aug 15, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you'll need to also drop rust-apply-patch.sh
and rust-release-main.yaml
from .github/workflows
- our package automation is going to take over updating rust.
sdk_container/src/third_party/coreos-overlay/profiles/coreos/base/package.unmask
Outdated
Show resolved
Hide resolved
It is not clear why this was forked originally. One reason was to avoid the sys-apps/lsb-release dependency, but it probably wasn't just that. It seems likely that the upstream package did not support cross targets at the time. Now it does. It appears that LTO was previously enabled by us following Gentoo rather than through an explicit decision. They now disable it by default, so we do likewise. It previously used "fat" LTO, which makes Rust especially slow to build and reportedly made rustc slower than with "thin" LTO! There seems little benefit in using thin LTO given that we rebuild Rust almost as much as the packages that use it, plus we don't enable LTO anywhere else. We still avoid rustdoc to keep the size down using INSTALL_MASK. This isn't as good as not building it in the first place, but this alone isn't worth keeping a fork. Cross targets are now handled via the admittedly experimental RUST_CROSS_TARGETS support. This has been in place for a while, and I think it is fairly widely used now. If it does disappear, it would almost certainly be for something even better. This also updates Rust from 1.80.0 to 1.80.1. Signed-off-by: James Le Cuirot <jlecuirot@microsoft.com>
chewi
force-pushed
the
chewi/gentoo-rust
branch
from
August 15, 2024 15:54
3bf7931
to
8e5b5af
Compare
krnowak
approved these changes
Aug 15, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Switch to Gentoo Rust package and upgrade to 1.80.1
It is not clear why this was forked originally. One reason was to avoid the sys-apps/lsb-release dependency, but it probably wasn't just that. It seems likely that the upstream package did not support cross targets at the time. Now it does.
The package builds significantly faster now that LTO is no longer enabled, especially given that it was the expensive "fat" LTO rather than "thin" LTO. The installed size is still kept down by masking rustdoc.
Cross targets are now handled via the admittedly experimental
RUST_CROSS_TARGETS
support. This has been in place for a while, and I think it is fairly widely used now. If it does disappear, it would almost certainly be for something even better.How to use
Nothing much to see. Grab the new SDK and build some Rust.
Testing done
This has been through many Jenkins runs. Everything looks good.
changelog/
directory (user-facing change, bug fix, security fix, update)/boot
and/usr
size, packages, list files for any missing binaries, kernel modules, config files, kernel modules, etc.