From 2b22576fb6a8bb52434068d95eff188a201e6bc5 Mon Sep 17 00:00:00 2001 From: John Ericson Date: Thu, 9 Aug 2018 16:06:55 -0400 Subject: Remove cross_info; cross file is parsed up front and discarded --- mesonbuild/modules/python3.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'mesonbuild/modules/python3.py') diff --git a/mesonbuild/modules/python3.py b/mesonbuild/modules/python3.py index f664632..46f15f0 100644 --- a/mesonbuild/modules/python3.py +++ b/mesonbuild/modules/python3.py @@ -48,10 +48,11 @@ class Python3Module(ExtensionModule): @noKwargs def find_python(self, state, args, kwargs): - options = [state.environment.config_info.binaries.get('python3')] - if not options[0]: # because this would be [None] - options = ['python3', mesonlib.python_command] - py3 = dependencies.ExternalProgram(*options, silent=True) + command = state.environment.binaries.host.lookup_entry('python3') + if command is not None: + py3 = dependencies.ExternalProgram.from_entry('python3', command) + else: + py3 = dependencies.ExternalProgram('python3', mesonlib.python_command, silent=True) return ModuleReturnValue(py3, [py3]) @noKwargs -- cgit v1.1