Rustup and rust dependencies

Hello crusties!

I've recently started using Solus OS, installed Rust with rustup, and I wanted to try writing a bit of code (and hopefully eventually contribute to some open source).

However, when I went to try and run the tiny first part of the program, cargo wouldn't build. Rustc on its own wouldn't compile it either. The problem was cc/ld linking. Installing gcc alone didn't help, so I checked the Solus software center. They're still on 1.17, but it helped me find the missing piece: glibc-devel.

Would it be possible/feasible to have rustup look for such dependencies, and suggest installing them as part of the installation process, if they are missing? Perhaps this is a niche problem (I don't think I had to manually install gcc or glibc-devel in Ubuntu), but might help some inexperienced users get started.

Thanks for reading. Sorry if this has already been addressed, but I couldn't find anything by searching.


It might be, but it's really hard, since each distro calls these packages something different.

I was considering putting this kind of thing in rustup for a while, but it's currently sidelined. It's a pretty big, ugly problem to identify the native toolchain dependencies on every platform.

In Fedora and RHEL, gcc requires glibc-devel. I find it strange that any distro wouldn't have that.

I don't think rustup should get too far into the weeds understanding platforms, but perhaps it could just check the PATH for cc, and print a warning/suggestion if it's not found.

1 Like

Good points. Maybe just a heads-up at the end to let people know "psst, you may need gcc/cygwin/xcode".

1 Like