aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/environment.py
diff options
context:
space:
mode:
authorJussi Pakkanen <jpakkane@gmail.com>2018-02-18 13:54:50 +0200
committerGitHub <noreply@github.com>2018-02-18 13:54:50 +0200
commit55a7c265c11e0f3e8a94cf9f4fd0b5f036a717d2 (patch)
tree29e6686ece50f119e8a4e850653c221b6872b975 /mesonbuild/environment.py
parent1841d53a84be13a3ba989b917930b824aafdac26 (diff)
parent7297e9f7a3581d132b0bccc47da4435c7315c74b (diff)
downloadmeson-55a7c265c11e0f3e8a94cf9f4fd0b5f036a717d2.zip
meson-55a7c265c11e0f3e8a94cf9f4fd0b5f036a717d2.tar.gz
meson-55a7c265c11e0f3e8a94cf9f4fd0b5f036a717d2.tar.bz2
Merge pull request #2863 from jon-turney/exit-status-on-exception
Verify that failing tests are failing with an error, not a python exception
Diffstat (limited to 'mesonbuild/environment.py')
-rw-r--r--mesonbuild/environment.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/mesonbuild/environment.py b/mesonbuild/environment.py
index 52c670a..e553423 100644
--- a/mesonbuild/environment.py
+++ b/mesonbuild/environment.py
@@ -695,10 +695,11 @@ class Environment:
for compiler in compilers:
if isinstance(compiler, str):
compiler = [compiler]
+ arg = ['--version']
try:
- p, out = Popen_safe(compiler + ['--version'])[0:2]
+ p, out = Popen_safe(compiler + arg)[0:2]
except OSError as e:
- popen_exceptions[compiler] = e
+ popen_exceptions[' '.join(compiler + arg)] = e
continue
version = search_version(out)