From 991baf56e99d96bbe3f2841f4b7c283e36ff1c89 Mon Sep 17 00:00:00 2001 From: Dylan Baker Date: Mon, 28 Feb 2022 14:25:10 -0800 Subject: modules/fs: Replace configure_file(copy:) with fs.copyfile `configure_file` is both an extremely complicated implementation, and a strange place for copying. It's a bit of a historical artifact, since the fs module didn't yet exist. It makes more sense to move this to the fs module and deprecate this `configure_file` version. This new version works at build time rather than configure time, which has the disadvantage it can't be passed to `run_command`, but with the advantage that changes to the input don't require a full reconfigure. --- mesonbuild/interpreter/interpreter.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'mesonbuild/interpreter/interpreter.py') diff --git a/mesonbuild/interpreter/interpreter.py b/mesonbuild/interpreter/interpreter.py index 5752d4c..b904055 100644 --- a/mesonbuild/interpreter/interpreter.py +++ b/mesonbuild/interpreter/interpreter.py @@ -2453,7 +2453,10 @@ class Interpreter(InterpreterBase, HoldableObject): 'configuration', (ContainerTypeInfo(dict, (str, int, bool)), build.ConfigurationData, NoneType), ), - KwargInfo('copy', bool, default=False, since='0.47.0'), + KwargInfo( + 'copy', bool, default=False, since='0.47.0', + deprecated='0.64.0', deprecated_message='Use fs.copy instead', + ), KwargInfo('encoding', str, default='utf-8', since='0.47.0'), KwargInfo('format', str, default='meson', since='0.46.0', validator=in_set_validator({'meson', 'cmake', 'cmake@'})), -- cgit v1.1