summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEduardo Lima (Etrunko) <etrunko@redhat.com>2018-08-30 11:58:55 -0300
committerFrediano Ziglio <fziglio@redhat.com>2018-09-03 08:53:01 +0100
commit6b93b3fce8909b836ef1d1434d191900d8aa00be (patch)
tree6ab5d53d16edc54fd43a9994c2ebae40f7b97960
parentbb15d4815ab586b4c4a20f4a565970a44824c42c (diff)
meson: Make use of compiler.get_supported_arguments()
This avoids adding an extra build flag which may not be supported by the compiler. Signed-off-by: Eduardo Lima (Etrunko) <etrunko@redhat.com>
-rw-r--r--meson.build5
1 files changed, 2 insertions, 3 deletions
diff --git a/meson.build b/meson.build
index 6fa67dc..5729d12 100644
--- a/meson.build
+++ b/meson.build
@@ -159,9 +159,8 @@ glib_encoded_version = 'GLIB_VERSION_@0@_@1@'.format(glib_major_minor[0], glib_m
spice_common_global_cflags += ['-DGLIB_VERSION_MIN_REQUIRED=@0@'.format(glib_encoded_version),
'-DGLIB_VERSION_MAX_ALLOWED=@0@'.format(glib_encoded_version)]
-foreach arg : spice_common_global_cflags
- add_project_arguments(arg, language : 'c')
-endforeach
+add_project_arguments(compiler.get_supported_arguments(spice_common_global_cflags),
+ language : 'c')
#
# Subdirectories