mirror of
https://gitlab.com/mishakmak/pam-fprint-grosshack.git
synced 2026-04-08 20:03:34 +02:00
meson: Fix CFLAGS use by using add_project_arguments
It seems that meson will not always apply the CFLAGS as defined through the environment if "c_args=" is used in the default_options array for the project() call. Switching to add_project_arguments solves this problem. See https://github.com/mesonbuild/meson/issues/8037
This commit is contained in:
committed by
Benjamin Berg
parent
df568e1ce1
commit
ec7376d7e6
18
meson.build
18
meson.build
@ -5,7 +5,14 @@ project('fprintd', 'c',
|
|||||||
'buildtype=debugoptimized',
|
'buildtype=debugoptimized',
|
||||||
'warning_level=1',
|
'warning_level=1',
|
||||||
'c_std=gnu99',
|
'c_std=gnu99',
|
||||||
'c_args=' + ' '.join([
|
],
|
||||||
|
meson_version: '>= 0.50.0')
|
||||||
|
|
||||||
|
gnome = import('gnome')
|
||||||
|
i18n = import('i18n')
|
||||||
|
|
||||||
|
cc = meson.get_compiler('c')
|
||||||
|
common_cflags = cc.get_supported_arguments([
|
||||||
'-fno-strict-aliasing',
|
'-fno-strict-aliasing',
|
||||||
'-Wall',
|
'-Wall',
|
||||||
'-Wcast-align',
|
'-Wcast-align',
|
||||||
@ -43,14 +50,9 @@ project('fprintd', 'c',
|
|||||||
'-Wtype-limits',
|
'-Wtype-limits',
|
||||||
'-Wundef',
|
'-Wundef',
|
||||||
'-Wunused',
|
'-Wunused',
|
||||||
]),
|
])
|
||||||
],
|
add_project_arguments(common_cflags, language: 'c')
|
||||||
meson_version: '>= 0.50.0')
|
|
||||||
|
|
||||||
gnome = import('gnome')
|
|
||||||
i18n = import('i18n')
|
|
||||||
|
|
||||||
cc = meson.get_compiler('c')
|
|
||||||
host_system = host_machine.system()
|
host_system = host_machine.system()
|
||||||
glib_min_version = '2.56'
|
glib_min_version = '2.56'
|
||||||
libfprint_min_version = '1.90.1'
|
libfprint_min_version = '1.90.1'
|
||||||
|
|||||||
Reference in New Issue
Block a user