aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/modules/python3.py
diff options
context:
space:
mode:
authorJussi Pakkanen <jpakkane@gmail.com>2018-11-15 22:47:51 +0200
committerGitHub <noreply@github.com>2018-11-15 22:47:51 +0200
commitc104251d2ef1ca1c4b8caea52fa6ab2da1dbaefe (patch)
tree0beb5ebae4bdbaf8e2385f644e7e6a8c406d0213 /mesonbuild/modules/python3.py
parent6a2dc7576e00e849510f7bc1f939d66d0b2f6f80 (diff)
parent0ab27add49cedb6f5985dfba7ba40c8d29ae91dc (diff)
downloadmeson-c104251d2ef1ca1c4b8caea52fa6ab2da1dbaefe.zip
meson-c104251d2ef1ca1c4b8caea52fa6ab2da1dbaefe.tar.gz
meson-c104251d2ef1ca1c4b8caea52fa6ab2da1dbaefe.tar.bz2
Merge pull request #4216 from dcbaker/wip/config-file
native file support
Diffstat (limited to 'mesonbuild/modules/python3.py')
-rw-r--r--mesonbuild/modules/python3.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/mesonbuild/modules/python3.py b/mesonbuild/modules/python3.py
index 5bda5ab..f664632 100644
--- a/mesonbuild/modules/python3.py
+++ b/mesonbuild/modules/python3.py
@@ -48,7 +48,10 @@ class Python3Module(ExtensionModule):
@noKwargs
def find_python(self, state, args, kwargs):
- py3 = dependencies.ExternalProgram('python3', mesonlib.python_command, silent=True)
+ 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)
return ModuleReturnValue(py3, [py3])
@noKwargs