meson: Do not add compiler flags if 'plain' buildtype is used

That is how the 'plain' buildtype is meant in meson.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/464
This commit is contained in:
Robert Mader 2019-04-29 12:59:56 +02:00 committed by Robert Mader
parent 83e83444db
commit de0e21612c

View File

@ -167,6 +167,8 @@ cdata.set('HAVE_FDWALK',
cc.has_function('fdwalk')
)
buildtype = get_option('buildtype')
if buildtype != 'plain'
all_warnings = [
'-fno-strict-aliasing',
'-Wpointer-arith',
@ -204,10 +206,9 @@ all_warnings = [
'-Werror=empty-body',
'-Werror=write-strings',
]
supported_warnings = cc.get_supported_arguments(all_warnings)
add_project_arguments(supported_warnings, language: 'c')
endif
if get_option('debug')
debug_c_args = [