Open the-kenny opened 8 years ago
Any comments here? Is this a feature that could make it into rustup
?
This has become more of a problem lately because rustup update
downloads rustup-init
and then immediately runs it (which fails for the reasons listed above). Before, I could at least download and patch rustup
and then the subsequently downloaded binaries (mainly rustc
and cargo
). Until we have a facility like the one mentioned above, I cannot update Rust on my system.
EDIT: I just found https://github.com/mozilla/nixpkgs-mozilla which appears to solve my issue.
The overlay from mozilla is very nice indeed, however I'd still prefer to be able to run rustup if necessary on my machine.
Heya ! Any news on this one ? Is it generally okay to implement such hooks, just no one has any bandwidth or is there a problem with the concept itself ? Thanks !
I don't think anyone in rustup has experience with NixOS and as such there's little interest for the limited bandwidth we do have. If you feel up to providing a PR, I'd be very happy to help you get it into a mergeable state.
Some news about this?
The state is the same as in the previous comment:
I don't think anyone in rustup has experience with NixOS and as such there's little interest for the limited bandwidth we do have. If you feel up to providing a PR, I'd be very happy to help you get it into a mergeable state.
Sorry for the long introduction, I'll try to keep it short:
I'm maintaining rust packages for NixOS, a linux distribution with an unique (purely functional) approach to packaging. Packages are reproducible, isolated, and immutable. One thing we do for this is to patch our binaries to use absolute paths for dynamically loaded libraries while not having a "classic"
/lib
or/usr/lib
directory.This also means that it's unfortunately not possible to run "normal" binaries (without absolute paths to dependencies or
/lib/ld-linux.so
) without patching them first. This also means that it's impossible to use the toolchains downloaded byrustup.rs
as-is without patching them first.I want to suggest adding an option to
rustup.rs
that will run a hook (any shell script or executable) right after switching (or downloading, doesn't really matter) of the toolchain. This would allow us to patch the toolchains and makerustup.rs
usable on NixOS.The great benefit of
rustup.rs
compared torustc
andcargo
in NixOS itself is that it makes it very easy to use recent nightly and beta builds. Right now these lack behind and they will get built from source as there isn't a binary substitution available from our build server (there is one for rustc-stable & cargo-stable).Is there a chance for such a feature to make it into
rustup.rs
? If someone can give me some pointers on where to start I'd be happy to take this on myself.