From: Andrea Bolognani Date: Wed, 26 Jan 2022 14:14:13 +0000 (+0100) Subject: meson: Require that both qemu_user and qemu_group are provided X-Git-Tag: v8.1.0-rc1~272 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=00c1a479142b653e21cf08a81099d7f6bb4da755;p=thirdparty%2Flibvirt.git meson: Require that both qemu_user and qemu_group are provided Or that neither is. The current implementation, where if only one of the two is provided the other one will be based on OS-specific defaults is more likely to cause confusion than it is to be helpful. Signed-off-by: Andrea Bolognani Reviewed-by: Pavel Hrdina --- diff --git a/meson.build b/meson.build index 5d8029a656..79c9fedea1 100644 --- a/meson.build +++ b/meson.build @@ -1683,10 +1683,13 @@ if not get_option('driver_qemu').disabled() endif endif qemu_user = get_option('qemu_user') + qemu_group = get_option('qemu_group') + if (qemu_user == '' and qemu_group != '') or (qemu_user != '' and qemu_group == '') + error('Please specify both qemu_user and qemu_group or neither of them') + endif if qemu_user == '' qemu_user = default_qemu_user endif - qemu_group = get_option('qemu_group') if qemu_group == '' qemu_group = default_qemu_group endif