aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarc-André Lureau <marcandre.lureau@redhat.com>2021-01-14 16:56:02 +0400
committerPaolo Bonzini <pbonzini@redhat.com>2021-01-23 09:26:40 -0500
commit5fc0617f134c7ce870a2b30762e099f6fedd4979 (patch)
treeb5e2e1fca78ff9f0e0b13097042069e5cdd01fd5
parent1df783eab50177e0510452cce99e49011dff4e5a (diff)
build-sys: set global arguments for cflags/ldflags
As we want subprojects to share those arguments Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Acked-by: Paolo Bonzini <pbonzini@redhat.com> Message-Id: <20210114125605.1227742-3-marcandre.lureau@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
-rw-r--r--meson.build16
1 files changed, 8 insertions, 8 deletions
diff --git a/meson.build b/meson.build
index 2001e941f4..e813814fb0 100644
--- a/meson.build
+++ b/meson.build
@@ -100,12 +100,12 @@ if 'CONFIG_FUZZ' in config_host
native: false, language: ['c', 'cpp', 'objc'])
endif
-add_project_arguments(config_host['QEMU_CFLAGS'].split(),
- native: false, language: ['c', 'objc'])
-add_project_arguments(config_host['QEMU_CXXFLAGS'].split(),
- native: false, language: 'cpp')
-add_project_link_arguments(config_host['QEMU_LDFLAGS'].split(),
- native: false, language: ['c', 'cpp', 'objc'])
+add_global_arguments(config_host['QEMU_CFLAGS'].split(),
+ native: false, language: ['c', 'objc'])
+add_global_arguments(config_host['QEMU_CXXFLAGS'].split(),
+ native: false, language: 'cpp')
+add_global_link_arguments(config_host['QEMU_LDFLAGS'].split(),
+ native: false, language: ['c', 'cpp', 'objc'])
if targetos == 'linux'
add_project_arguments('-isystem', meson.current_source_dir() / 'linux-headers',
@@ -1021,8 +1021,8 @@ if get_option('cfi')
error('-fno-sanitize-trap=cfi-icall is not supported by the compiler')
endif
endif
- add_project_arguments(cfi_flags, native: false, language: ['c', 'cpp', 'objc'])
- add_project_link_arguments(cfi_flags, native: false, language: ['c', 'cpp', 'objc'])
+ add_global_arguments(cfi_flags, native: false, language: ['c', 'cpp', 'objc'])
+ add_global_link_arguments(cfi_flags, native: false, language: ['c', 'cpp', 'objc'])
endif
#################