Hi Marc-André,

Thank you for working on this patch.

> wasm-ld: error: unable to find library -llibqemuutil.a

This issue looks similar to the one in "[PATCH v2 24/27] WIP: cirrus/macos:
enable Rust" so I tried the upcoming meson change[1] mentioned in that
patch for the wasm build. By also applying a patch for disabling the
"verbatim" modifier for the Emscripten build[2], I was able to avoid the
error.

However the test build still fails with the following error[3] which I'm
currently investigating. It seems that meson invokes rustc with duplicated
linker flags (e.g. I saw three "-lstatic:-bundle=glib-2.0" flags in a single
rustc invocation) and rustc doesn't seem capable of handling them.

> error: overriding linking modifiers from command line is not supported

Aside from the test build, I also tried building the qemu binary. The build
succeeded after rebuilding the Rust standard library as suggested in the
documentation[4]. If you're interested, I've stored the patch to [5].

[1] https://github.com/mesonbuild/meson/pull/15024
[2] https://github.com/ktock/meson/commit/afd0366d1fafe0cee2915d4b60bc2b523e3c1c02
[3] https://gitlab.com/ktock/qemu/-/jobs/11529682431#L3287
[4] https://github.com/rust-lang/rust/blob/5b9007bfc358817cf066ee27c6b440440727d3a7/src/doc/rustc/src/platform-support/wasm32-unknown-emscripten.md#emscripten-abi-compatibility
[5] https://gitlab.com/ktock/qemu/-/commits/test-rust-emscripten-c

Regards,
Kohei