diff options
author | Paolo Bonzini <pbonzini@redhat.com> | 2022-10-12 11:31:32 +0200 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2023-05-18 08:53:52 +0200 |
commit | fc9a809e0d28417fa1e7f7efc19f845bda4c1be9 (patch) | |
tree | 8f343c10516cee787f6ad550b955a816b732ea86 /util | |
parent | 5328353c05d880fbdba16a968cf9a39c8bd11a14 (diff) |
build: move glib detection and workarounds to meson
QEMU adds the path to glib.h to all compilation commands. This is simpler
due to the pervasive use of static_library, and was grandfathered in from
the previous Make-based build system. Until Meson 0.63 the only way to
do this was to detect glib in configure and use add_project_arguments,
but now it is possible to use add_project_dependencies instead.
gmodule is detected in a separate variable, with export enabled for
modules and disabled for plugin.
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'util')
-rw-r--r-- | util/meson.build | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/util/meson.build b/util/meson.build index 3c2cfc6ede..2cb103fc72 100644 --- a/util/meson.build +++ b/util/meson.build @@ -26,7 +26,9 @@ util_ss.add(when: 'CONFIG_WIN32', if_true: files('oslib-win32.c')) util_ss.add(when: 'CONFIG_WIN32', if_true: files('qemu-thread-win32.c')) util_ss.add(when: 'CONFIG_WIN32', if_true: winmm) util_ss.add(when: 'CONFIG_WIN32', if_true: pathcch) -util_ss.add(when: 'HAVE_GLIB_WITH_SLICE_ALLOCATOR', if_true: files('qtree.c')) +if glib_has_gslice + util_ss.add(files('qtree.c')) +endif util_ss.add(files('envlist.c', 'path.c', 'module.c')) util_ss.add(files('host-utils.c')) util_ss.add(files('bitmap.c', 'bitops.c')) |