aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEli Schwartz <eschwartz@archlinux.org>2022-07-12 21:43:52 -0400
committerNirbheek Chauhan <nirbheek@centricular.com>2022-08-08 19:13:43 +0530
commit15e5830dd84e540357c5d9948b8bf19f909b6d28 (patch)
treef68d395a2ef4f756a82bb1aa3cf7cf1e917482b2
parent2ba0a50f066413ebd8c863afac185c291c1d8e96 (diff)
downloadmeson-15e5830dd84e540357c5d9948b8bf19f909b6d28.zip
meson-15e5830dd84e540357c5d9948b8bf19f909b6d28.tar.gz
meson-15e5830dd84e540357c5d9948b8bf19f909b6d28.tar.bz2
compilers: include compiler detection output in the debug logs
We do something similar when running get_compiler() method checks from the DSL. This ensures that if errors happen, the log file we tell people to check actually works.
-rw-r--r--mesonbuild/compilers/detect.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/mesonbuild/compilers/detect.py b/mesonbuild/compilers/detect.py
index 0a113d0..09a0345 100644
--- a/mesonbuild/compilers/detect.py
+++ b/mesonbuild/compilers/detect.py
@@ -419,7 +419,12 @@ def _detect_c_or_cpp_compiler(env: 'Environment', lang: str, for_machine: Machin
cmd = compiler + [arg]
try:
+ mlog.debug('-----')
+ mlog.debug(f'Detecting compiler via: {join_args(cmd)}')
p, out, err = Popen_safe(cmd)
+ mlog.debug(f'compiler returned {p}')
+ mlog.debug(f'compiler stdout:\n{out}')
+ mlog.debug(f'compiler stderr:\n{err}')
except OSError as e:
popen_exceptions[join_args(cmd)] = e
continue