summaryrefslogtreecommitdiffstats
path: root/meson.build
diff options
context:
space:
mode:
authorMarc-André Lureau2020-09-11 14:42:48 +0200
committerPaolo Bonzini2020-09-30 19:09:19 +0200
commit8fe11232c8ad0fecbfab0ea804bfdef0bbec0da7 (patch)
tree0edf08a0682e0ac3bf15db7ed63e7146706a0acc /meson.build
parentmeson: fix MSI rule (diff)
downloadqemu-8fe11232c8ad0fecbfab0ea804bfdef0bbec0da7.tar.gz
qemu-8fe11232c8ad0fecbfab0ea804bfdef0bbec0da7.tar.xz
qemu-8fe11232c8ad0fecbfab0ea804bfdef0bbec0da7.zip
meson: error out if qemu_suffix starts with /
Since the variable is used for path concatenation, the result would ignore the prefix directory altogether. Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build5
1 files changed, 5 insertions, 0 deletions
diff --git a/meson.build b/meson.build
index 5b586afc38..9755be79fd 100644
--- a/meson.build
+++ b/meson.build
@@ -17,6 +17,11 @@ config_host = keyval.load(meson.current_build_dir() / 'config-host.mak')
enable_modules = 'CONFIG_MODULES' in config_host
enable_static = 'CONFIG_STATIC' in config_host
build_docs = 'BUILD_DOCS' in config_host
+
+if get_option('qemu_suffix').startswith('/')
+ error('qemu_suffix cannot start with a /')
+endif
+
qemu_datadir = get_option('datadir') / get_option('qemu_suffix')
qemu_docdir = get_option('docdir') / get_option('qemu_suffix')
config_host_data = configuration_data()