On 2025/06/05 22:24, Paolo Bonzini wrote:
From: Akihiko Odaki <akihiko.od...@daynix.com>
In a recent discussion, Phil Dennis-Jordan pointed out a quirk in
QemuEvent destruction due to futex-like abstraction, which prevented
the usage of QemuEvent in new and existing code[1]. With some more
thoughts after this discussion, I also found other problem and room
of improvement in futex usage. Here is a stack of patches to resolve
them.
Thanks. I haven't had the time to go through the final two patches,
so I took the current Linux code unmodified and added the non-Linux
changes on top. But I have kept the delta locally and will get back
to it.
I also had to squash this in for CI to pass:
diff --git a/meson.build b/meson.build
index 20e8f37e6e7..34729c2a3dd 100644
--- a/meson.build
+++ b/meson.build
@@ -843,7 +843,12 @@ if host_os == 'windows'
midl = find_program('midl', required: false)
widl = find_program('widl', required: false)
pathcch = cc.find_library('pathcch')
- synchronization = cc.find_library('Synchronization')
+ synchronization = cc.find_library('Synchronization', required: false)
+ if not synchronization.found()
+ # The library name is lowercase on mingw
+ synchronization = cc.find_library('synchronization', required: true)
+ endif
+
This conditional is unnecessary; docs/about/build-platforms.rst says we
only supports MinGW.
I failed to catch this problem because I ran MinGW on Windows, which is
case-insensitive. Since it is case-insensitive, the lowercase name will
work for the OS too.
Regards,
Akihiko Odaki