Multirust 0.7, now with MSYS2 support


#1

Hey, folks.

Multirust, the tiny shell script that manages multiple installs of Rust, now supports Windows under MSYS2, thanks to the efforts of @SpaceManiac.

It’s only lightly tested, but the test suite at least passes. I suggest uninstalling any existing Rust before installing multirust (just to avoid confusion - it shouldn’t cause problems). Note also that multirust does not use the .msi installers on windows, so you will find neither Rust nor multirust
in your installed applications list.

Install like so:

curl -sf https://raw.githubusercontent.com/brson/multirust/master/blastoff.sh | sh

Other recent changes:

Thanks to those who have contributed recently: @tamird, @aaparella, @LukasKalbertodt, Kai Lieth, @shaleh, @jcaudle, @SpaceManiac.

Happy hacking.


#2

I don’t know if Cygwin is meant to be supported – if MSYS2 works then I don’t see why not. But FYI I ran into this issue: https://github.com/rust-lang/rust-installer/issues/43


#3

I’d like to support Cygwin. I’ll give it a look this afternoon.


#4

FWIW, I hacked it into a wildcard for CYGWIN_NT-*, and similarly added it to rustup, and things seem fine!

I suspect rust-installer’s code was copied from rust’s configure script, which also needs help. And my WOW64 comments in the issue are probably more relevant there. I’ve never tried building Rust under Cygwin, and don’t really need to, but maybe I can give this a shot this weekend…


#5

Awesome! Will you submit some patches?


#6

FWIW, @alexcrichton discovered a way in which multirust/win behaves differently than multirust/unix: when cargo invokes rustc, instead of calling the multirustproxy shell script it calls cargo directly. I don’t anticipate this causing major problems, but there are definitely some corner cases that will behave differently.


#7

See rust-installer#44 and rustup#31.

I assume you meant it calls rustc directly. But a native Windows cargo will have no idea how to execute a shell script, so it couldn’t use multirustproxy even if it tried. Fine with me. :slight_smile:


#8

Thanks.

Yes.


#9

Right now multirust isn’t installed on Git for Windows (MINGW64_NT-6.1) because /usr/local doesn’t exists (git installer doesn’t create such directories). Could you please change installation folder to another one? %LOCALAPPDATA% is good enough.


#10

Here’s the issue for Git for Windows