From 614ba114ef48bf77cd9bcc366706290d2a454441 Mon Sep 17 00:00:00 2001 From: Eberhard Beilharz Date: Thu, 28 Oct 2021 11:36:09 +0200 Subject: [PATCH] chore(common): Work with older meson versions The copy keyword inside of configure_file got added in meson 0.47. However, we still support Bionic which comes with meson 0.45. This change adds a workaround. --- common/core/desktop/tests/unit/kmx/meson.build | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/common/core/desktop/tests/unit/kmx/meson.build b/common/core/desktop/tests/unit/kmx/meson.build index 4e62f897ee..6836d4f0ee 100644 --- a/common/core/desktop/tests/unit/kmx/meson.build +++ b/common/core/desktop/tests/unit/kmx/meson.build @@ -78,6 +78,7 @@ tests = [ if build_machine.system() == 'windows' kmcomp = find_program('kmcomp.exe', required: false) kmcomp_cmd = [kmcomp] + copy_cmd = [find_program('cmd.exe', required: true), '/c', 'copy'] else kmcomp = find_program('kmcomp', required: false) kmcomp_cmd = [kmcomp] @@ -89,6 +90,7 @@ else kmcomp = disabler() endif endif + copy_cmd = [find_program('cp', required: true)] endif if compiler.get_id() == 'emscripten' @@ -115,13 +117,13 @@ foreach kbd : tests ] }''' configure_file( - copy: true, + command: copy_cmd + ['@INPUT@', '@OUTPUT@'], input: kbd + '.kmn', output: kbd + '.kmn' ) if not kmcomp.found() configure_file( - copy: true, + command: copy_cmd + ['@INPUT@', '@OUTPUT@'], input: kbd + '.kmx', output: kbd + '.kmx' )