mirror of
https://github.com/qemu/qemu.git
synced 2026-01-14 03:01:08 +00:00
With the bump to Meson 1.10.0, C objects can be passed to rust targets. This way, the Rust libstd will be added by rustc itself in its final linker invocation. Use that to eliminate the staticlib and allow dynamic linking with libstd (also introduced by Meson 1.9.0, but not for staticlib crates due to lack of support in rustc). The main() function is still provided by C, which is possible by declaring the main source file of the Rust executable (which is still created by scripts/rust/rust_root_crate.sh) as #![no_main]. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>