aboutsummaryrefslogtreecommitdiff
path: root/meson.build
diff options
context:
space:
mode:
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build30
1 files changed, 29 insertions, 1 deletions
diff --git a/meson.build b/meson.build
index 0458b69cdf..9efcb175d1 100644
--- a/meson.build
+++ b/meson.build
@@ -312,6 +312,10 @@ multiprocess_allowed = get_option('multiprocess') \
.require(targetos == 'linux', error_message: 'Multiprocess QEMU is supported only on Linux') \
.allowed()
+vfio_user_server_allowed = get_option('vfio_user_server') \
+ .require(targetos == 'linux', error_message: 'vfio-user server is supported only on Linux') \
+ .allowed()
+
have_tpm = get_option('tpm') \
.require(targetos != 'windows', error_message: 'TPM emulation only available on POSIX systems') \
.allowed()
@@ -1412,6 +1416,12 @@ if have_system
method: 'pkg-config',
kwargs: static_kwargs)
endif
+canokey = not_found
+if have_system
+ canokey = dependency('canokey-qemu', required: get_option('canokey'),
+ method: 'pkg-config',
+ kwargs: static_kwargs)
+endif
usbredir = not_found
if not get_option('usb_redir').auto() or have_system
usbredir = dependency('libusbredirparser-0.5', required: get_option('usb_redir'),
@@ -1750,6 +1760,7 @@ config_host_data.set('CONFIG_LIBNFS', libnfs.found())
config_host_data.set('CONFIG_LIBSSH', libssh.found())
config_host_data.set('CONFIG_LINUX_AIO', libaio.found())
config_host_data.set('CONFIG_LINUX_IO_URING', linux_io_uring.found())
+config_host_data.set('CONFIG_LIBURING_REGISTER_RING_FD', cc.has_function('io_uring_register_ring_fd', prefix: '#include <liburing.h>', dependencies:linux_io_uring))
config_host_data.set('CONFIG_LIBPMEM', libpmem.found())
config_host_data.set('CONFIG_NUMA', numa.found())
config_host_data.set('CONFIG_OPENGL', opengl.found())
@@ -2377,7 +2388,8 @@ host_kconfig = \
(have_virtfs ? ['CONFIG_VIRTFS=y'] : []) + \
('CONFIG_LINUX' in config_host ? ['CONFIG_LINUX=y'] : []) + \
(have_pvrdma ? ['CONFIG_PVRDMA=y'] : []) + \
- (multiprocess_allowed ? ['CONFIG_MULTIPROCESS_ALLOWED=y'] : [])
+ (multiprocess_allowed ? ['CONFIG_MULTIPROCESS_ALLOWED=y'] : []) + \
+ (vfio_user_server_allowed ? ['CONFIG_VFIO_USER_SERVER_ALLOWED=y'] : [])
ignored = [ 'TARGET_XML_FILES', 'TARGET_ABI_DIR', 'TARGET_ARCH' ]
@@ -2669,6 +2681,21 @@ if have_system
endif
endif
+libvfio_user_dep = not_found
+if have_system and vfio_user_server_allowed
+ have_internal = fs.exists(meson.current_source_dir() / 'subprojects/libvfio-user/meson.build')
+
+ if not have_internal
+ error('libvfio-user source not found - please pull git submodule')
+ endif
+
+ libvfio_user_proj = subproject('libvfio-user')
+
+ libvfio_user_lib = libvfio_user_proj.get_variable('libvfio_user_dep')
+
+ libvfio_user_dep = declare_dependency(dependencies: [libvfio_user_lib])
+endif
+
fdt = not_found
if have_system
fdt_opt = get_option('fdt')
@@ -3790,6 +3817,7 @@ summary_info += {'target list': ' '.join(target_dirs)}
if have_system
summary_info += {'default devices': get_option('default_devices')}
summary_info += {'out of process emulation': multiprocess_allowed}
+ summary_info += {'vfio-user server': vfio_user_server_allowed}
endif
summary(summary_info, bool_yn: true, section: 'Targets and accelerators')