-
Notifications
You must be signed in to change notification settings - Fork 14k
Description
Please add the ability to pass RUSTFLAGS (or equivalent) to targets when using x.py. Right now, the only way is to pass environment variables, and even then it straight-up ignores them sometimes.
It also does weird stuff with copying files from the sysroot or failing with missing CRT files that I don't understand. Why does building Rust itself and cross-compiling the standard library work this way?
Clang is the linker, and I want to pass arguments per-target: --sysroot, include dirs, library dirs, etc., and just build. But no. x.py literally rebuilds the compiler every time I try to build the standard library, even if I tell it in bootstrap.toml to just use my existing rustc.
People literally embed Rust dependencies into C/C++ or Python projects. Why is this workflow (installing from source) so different?
I will not use binary distributions. Platform defaults aren’t always the same. I don’t want to rely on libstdc++ or gcc_s for Linux builds. I just want: target-specific flags + existing compiler + build stdlib — what can be done to make this easier?