From 6e200222957063819a00e3bf767ce28b7489c31f Mon Sep 17 00:00:00 2001 From: Jussi Pakkanen Date: Sun, 14 Jul 2024 19:33:41 +0300 Subject: Remove module type from OptionKey. --- mesonbuild/modules/python.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'mesonbuild/modules/python.py') diff --git a/mesonbuild/modules/python.py b/mesonbuild/modules/python.py index dec77e249..1b7a05640 100644 --- a/mesonbuild/modules/python.py +++ b/mesonbuild/modules/python.py @@ -83,13 +83,13 @@ class PythonExternalProgram(BasicPythonExternalProgram): if not state: # This happens only from run_project_tests.py return rel_path - value = T.cast('str', state.get_option(f'{key}dir', module='python')) + value = T.cast('str', state.get_option(f'python.{key}dir')) if value: - if state.is_user_defined_option('install_env', module='python'): + if state.is_user_defined_option('python.install_env'): raise mesonlib.MesonException(f'python.{key}dir and python.install_env are mutually exclusive') return value - install_env = state.get_option('install_env', module='python') + install_env = state.get_option('python.install_env') if install_env == 'auto': install_env = 'venv' if self.info['is_venv'] else 'system' @@ -169,7 +169,7 @@ class PythonInstallation(_ExternalProgramHolder['PythonExternalProgram']): self.current_node) limited_api_version = kwargs.pop('limited_api') - allow_limited_api = self.interpreter.environment.coredata.get_option(OptionKey('allow_limited_api', module='python')) + allow_limited_api = self.interpreter.environment.coredata.get_option(OptionKey('python.allow_limited_api')) if limited_api_version != '' and allow_limited_api: target_suffix = self.limited_api_suffix @@ -374,7 +374,7 @@ class PythonModule(ExtensionModule): def _get_install_scripts(self) -> T.List[mesonlib.ExecutableSerialisation]: backend = self.interpreter.backend ret = [] - optlevel = self.interpreter.environment.coredata.get_option(OptionKey('bytecompile', module='python')) + optlevel = self.interpreter.environment.coredata.get_option(OptionKey('python.bytecompile')) if optlevel == -1: return ret if not any(PythonExternalProgram.run_bytecompile.values()): -- cgit v1.2.3