Packaging Rust applications build using the nightly toolchain
Hello, Does anyone know if there's a proper way to package rust applications (via obs) using the nightly toolchain? A lot of newer Rust features are currently still only found in the nightly release channel, and projects can typically use rust-toolchain.toml[1] file to specify what version of nightly is used. However there's no way to draw in these toolchains as a dependency in the specfile (that I am aware of). I know that other distributions like Fedora simply do not support the nightly toolchain for its packages[2]. But I feel like this is kind of a shame as so much functionality is found in nightly. My personal projects typically rely on at least a couple of nightly features. [1]: https://rust-lang.github.io/rustup/overrides.html#the-toolchain-file [2]: https://docs.fedoraproject.org/en-US/packaging-guidelines/Rust/
On Sunday 2024-11-24 14:19, Rein Fernhout (Levitating) wrote:
Does anyone know if there's a proper way to package rust applications (via obs) using the nightly toolchain? I know that other distributions like Fedora simply do not support the nightly toolchain for its packages[2]. But I feel like this is kind of a shame as so much functionality is found in nightly.
When everybody runs at breakneck pace, don't complain if a few necks break. But we like to keep ours intact.
Am 24.11.24 um 14:19 schrieb Rein Fernhout (Levitating):
A lot of newer Rust features are currently still only found in the nightly release channel
If upstream decides they don't want these features in their releases we'll typically stick to that decision. Still, if there are build-time feature toggles, you could ask the Rust package maintainers (e.g. via bug report) to enable them.
My personal projects typically rely on at least a couple of nightly features.
This might be what upstream wants to prevent. They might want to be able to play with these features without fear of breaking shipped software. So relying on these features in packaging would be antithetical. In C++, experimental features are usually shipped behind feature flags. You can even compile against unfinished standard versions. (Quite famously C++0x, which then became C++11 with some delay.) With those flags, you're explicitly opting into unstable features that you know might break. But if Rust doesn't want to go this route, I doubt that our package maintainers will be willing to change that. Aaron
participants (3)
-
Aaron Puchert
-
Jan Engelhardt
-
Rein Fernhout (Levitating)