build: Stop using Meson features deprecated in Meson <0.60

This clears some Meson warnings.

Signed-off-by: Philip Withnall <pwithnall@endlessos.org>
This commit is contained in:
Philip Withnall 2022-05-06 13:16:26 +01:00
parent 374be41433
commit bd1781a356
5 changed files with 13 additions and 13 deletions

View File

@ -774,7 +774,7 @@ if have_bash
bash_comp_inst_dir = ''
if bash_comp_dep.found()
bash_comp_dir_override = bash_comp_dep.version().version_compare('>= 2.10') ? ['datadir', get_option('datadir')] : ['prefix', get_option('prefix')]
bash_comp_inst_dir = bash_comp_dep.get_pkgconfig_variable('completionsdir', define_variable: bash_comp_dir_override)
bash_comp_inst_dir = bash_comp_dep.get_variable('completionsdir', pkgconfig_define: bash_comp_dir_override)
endif
if bash_comp_inst_dir == ''

View File

@ -830,7 +830,7 @@ foreach test_name, extra_args : gio_tests
foreach var, value : installed_tests_env
envs += '@0@=@1@'.format(var, value)
endforeach
test_env_override = '@0@ @1@ '.format(env_program.path(), ' '.join(envs))
test_env_override = '@0@ @1@ '.format(env_program.full_path(), ' '.join(envs))
endif
test_conf.set('env', test_env_override)
configure_file(

View File

@ -408,7 +408,7 @@ if host_system == 'windows'
if host_machine.cpu_family() == 'x86'
executable('gspawn-win32-helper', 'gspawn-win32-helper.c',
install : true,
gui_app : true,
win_subsystem : 'windows',
include_directories : configinc,
dependencies : [libglib_dep])
executable('gspawn-win32-helper-console', 'gspawn-win32-helper.c',
@ -419,7 +419,7 @@ if host_system == 'windows'
else
executable('gspawn-win64-helper', 'gspawn-win32-helper.c',
install : true,
gui_app : true,
win_subsystem : 'windows',
include_directories : configinc,
dependencies : [libglib_dep])
executable('gspawn-win64-helper-console', 'gspawn-win32-helper.c',

View File

@ -1034,7 +1034,7 @@ main(void)
have_good_vsnprintf = true
endif
else
have_good_vsnprintf = meson.get_cross_property('have_c99_vsnprintf', false)
have_good_vsnprintf = meson.get_external_property('have_c99_vsnprintf', false)
glib_conf.set('HAVE_C99_VSNPRINTF', have_good_vsnprintf)
endif
@ -1082,7 +1082,7 @@ main(void)
have_good_snprintf = true
endif
else
have_good_snprintf = meson.get_cross_property('have_c99_snprintf', false)
have_good_snprintf = meson.get_external_property('have_c99_snprintf', false)
glib_conf.set('HAVE_C99_SNPRINTF', have_good_snprintf)
endif
@ -1109,7 +1109,7 @@ main (void)
have_good_printf = true
endif
else
have_good_printf = meson.get_cross_property('have_unix98_printf', false)
have_good_printf = meson.get_external_property('have_unix98_printf', false)
glib_conf.set('HAVE_UNIX98_PRINTF', have_good_printf)
endif
endif
@ -1703,7 +1703,7 @@ if cc_can_run
rres = cc.run(va_list_val_copy_prog, name : 'va_lists can be copied as values')
glib_va_val_copy = rres.returncode() == 0
else
glib_va_val_copy = meson.get_cross_property('va_val_copy', true)
glib_va_val_copy = meson.get_external_property('va_val_copy', true)
endif
if not glib_va_val_copy
glib_vacopy = glib_vacopy + '\n#define G_VA_COPY_AS_ARRAY 1'
@ -1982,7 +1982,7 @@ if cc_can_run
rres = cc.run(stack_grows_check_prog, name : 'stack grows check')
growing_stack = rres.returncode() == 0
else
growing_stack = meson.get_cross_property('growing_stack', false)
growing_stack = meson.get_external_property('growing_stack', false)
endif
glibconfig_conf.set10('G_HAVE_GROWING_STACK', growing_stack)
@ -2201,7 +2201,7 @@ if cc.has_function('strlcpy')
if rres.compiled() and rres.returncode() == 0
glib_conf.set('HAVE_STRLCPY', 1)
endif
elif meson.get_cross_property('have_strlcpy', false)
elif meson.get_external_property('have_strlcpy', false)
glib_conf.set('HAVE_STRLCPY', 1)
endif
endif
@ -2258,7 +2258,7 @@ if cc_can_run
rres = cc.run(cmdline_test_code, name : '/proc/self/cmdline')
have_proc_self_cmdline = rres.compiled() and rres.returncode() == 0
else
have_proc_self_cmdline = meson.get_cross_property('have_proc_self_cmdline', false)
have_proc_self_cmdline = meson.get_external_property('have_proc_self_cmdline', false)
endif
glib_conf.set('HAVE_PROC_SELF_CMDLINE', have_proc_self_cmdline)

View File

@ -46,7 +46,7 @@ test_extra_programs = {
if host_machine.system() == 'windows'
test_extra_programs += {
'spawn-test-win32-gui' : {'gui_app' : true}
'spawn-test-win32-gui' : {'win_subsystem' : 'windows'}
}
endif
@ -119,6 +119,6 @@ foreach program_name, extra_args : test_extra_programs
dependencies : common_deps + extra_args.get('dependencies', []),
install_dir : installed_tests_execdir,
install : install,
gui_app : extra_args.get('gui_app', false),
win_subsystem : extra_args.get('win_subsystem', 'console'),
)
endforeach