aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2020-10-19 07:04:39 -0400
committerDylan Baker <dylan@pnwbakers.com>2020-10-19 09:40:31 -0700
commitdf29f760dd1c8e22ae431ba01b07faf55bf1ff60 (patch)
treecb74b5dd9f32ce1574f3da2c6b93adeb29222433
parentfaabbb3bb2389ad4e5e88a181e37d19efb708811 (diff)
downloadmeson-df29f760dd1c8e22ae431ba01b07faf55bf1ff60.zip
meson-df29f760dd1c8e22ae431ba01b07faf55bf1ff60.tar.gz
meson-df29f760dd1c8e22ae431ba01b07faf55bf1ff60.tar.bz2
switch gui_app deprecation to FeatureDeprecatedKwargs
The deprecation message for "gui_app" is appearing for every target rather than just once, and even if the required version is older than 0.56.0. Use @FeatureDeprecatedKwargs to fix both issues.
-rw-r--r--mesonbuild/build.py1
-rw-r--r--mesonbuild/interpreter.py1
2 files changed, 1 insertions, 1 deletions
diff --git a/mesonbuild/build.py b/mesonbuild/build.py
index 4723636..78292f2 100644
--- a/mesonbuild/build.py
+++ b/mesonbuild/build.py
@@ -929,7 +929,6 @@ This will become a hard error in a future Meson release.''')
# was not specified and win_subsystem should be used instead.
self.gui_app = None
if 'gui_app' in kwargs:
- mlog.deprecation('The gui_app kwarg is deprecated, use win_subsystem instead.')
if 'win_subsystem' in kwargs:
raise InvalidArguments('Can specify only gui_app or win_subsystem for a target, not both.')
self.gui_app = kwargs['gui_app']
diff --git a/mesonbuild/interpreter.py b/mesonbuild/interpreter.py
index 0dc38f3..c67341a 100644
--- a/mesonbuild/interpreter.py
+++ b/mesonbuild/interpreter.py
@@ -3874,6 +3874,7 @@ external dependencies (including libraries) must go to "dependencies".''')
@FeatureNewKwargs('executable', '0.42.0', ['implib'])
@permittedKwargs(permitted_kwargs['executable'])
+ @FeatureDeprecatedKwargs('executable', '0.56.0', ['gui_app'], extra_message="Use 'win_subsystem' instead.")
def func_executable(self, node, args, kwargs):
return self.build_target(node, args, kwargs, ExecutableHolder)