If the user explicitly asked for the system libfdt library, but the library is not usable (usually too old), we should not silently default to the internal one. Respect the user decision, and only default to 'internal' if in auto mode.
Fixes: fbb4121d592 ("dtc: Convert Makefile bits to meson bits") Reported-by: John Paul Adrian Glaubitz <glaub...@physik.fu-berlin.de> BugLink: https://bugs.launchpad.net/qemu/+bug/1907427 Fixes: https://gitlab.com/qemu-project/qemu/-/issues/255 Signed-off-by: Philippe Mathieu-Daudé <phi...@redhat.com> --- meson.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meson.build b/meson.build index 0b41ff41188..1ffb4bccdb2 100644 --- a/meson.build +++ b/meson.build @@ -1612,7 +1612,7 @@ int main(void) { fdt_check_full(NULL, 0); return 0; }''', dependencies: fdt) fdt_opt = 'system' - elif have_internal + elif have_internal and fdt_opt in ['enabled', 'auto'] fdt_opt = 'internal' else fdt_opt = 'disabled' -- 2.26.3