On 08/10/21 10:47, Marc-André Lureau wrote:
It looks silly but it works ("when: []" is always-true, just like in
python all([]) is true). I'll remove the if_true in v2.
and why not keep the one-liner version?:
stub_ss.add(when: libaio, if_true: files('linux-aio.c'))
It would link libaio even in files that don't use it. The stub is used
by those files that get util/async.c via libqemuutil, but not
block/linux-aio.c.
This particular stub (and the equivalent io_uring one) is a bit silly
though.
Someone should check exactly which files get which stub, maybe there are
opportunities for simplifications. For example if a stub is only used
by the unit tests, we might as well move more code to libqemuutil and
remove the stub.
Paolo