4 ms·
It was popular demand because tooling was not mature. Now we want to install programs, which are written in Rust, using system package manager, thus we demand d
by v_lisivka 9y ago
It was popular demand because tooling was not mature. Now we want to install programs, which are written in Rust, using system package manager, thus we demand dynamic linking.
Moreover, when part of program is static and part is dynamically linked to a C library, it does not matter any more.
For embedded systems, dynamic linking is better when more than one running application is written in Rust, to save memory and processor cache.
- pcwalton 9y agoDynamic linking is fully supported by Rust. Just pass -C prefer-dynamic in your RUSTFLAGS.
- v_lisivka 9y agoBut ABI is not fixed yet, so all libraries and binary must be compiled by same compiler with same options.
- tmzt 9y agoSince the parent mentioned installing using a package manager, could it be default in that case as well as in the `cargo install` case where cargo essentially controls the binary? If not default, could it be more easily chosen with a shorter option? Is a rust heap/runtime packaged for distros like Debian which have packaged binaries of some crates? Note, I'm not in favor of making dynamic default for `cargo build`.