Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nodejs/node.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Lau <riclau@uk.ibm.com>2020-04-08 13:42:25 +0300
committerRichard Lau <riclau@uk.ibm.com>2020-07-01 13:47:37 +0300
commit9915774d181914349d8dda4577cb7875e47a1008 (patch)
tree03bab0bbb1b3b6a0445054a659068e8aba766c07
parent543656928c8bd5582e14cf13067893b15a141b63 (diff)
build: log detected compilers in --verbose mode
Log the versions of the detected compilers when the configure script is run with `--verbose` to help verify which compiler is being used if multiple toolchains are installed on the system. Signed-off-by: Richard Lau <riclau@uk.ibm.com> PR-URL: https://github.com/nodejs/node/pull/32715 Backport-PR-URL: https://github.com/nodejs/node/pull/32820 Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com> Reviewed-By: Rod Vagg <rod@vagg.org> Reviewed-By: Sam Roberts <vieuxtech@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net>
-rwxr-xr-xconfigure.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/configure.py b/configure.py
index 55df96595ac..89f7bf5b7bf 100755
--- a/configure.py
+++ b/configure.py
@@ -750,6 +750,9 @@ def check_compiler(o):
return
ok, is_clang, clang_version, gcc_version = try_check_compiler(CXX, 'c++')
+ version_str = ".".join(map(str, clang_version if is_clang else gcc_version))
+ print_verbose('Detected %sC++ compiler (CXX=%s) version: %s' %
+ ('clang ' if is_clang else '', CXX, version_str))
if not ok:
warn('failed to autodetect C++ compiler version (CXX=%s)' % CXX)
elif sys.platform.startswith('aix') and gcc_version < (6, 3, 0):
@@ -758,6 +761,9 @@ def check_compiler(o):
warn('C++ compiler too old, need g++ 4.9.4 or clang++ 3.4.2 (CXX=%s)' % CXX)
ok, is_clang, clang_version, gcc_version = try_check_compiler(CC, 'c')
+ version_str = ".".join(map(str, clang_version if is_clang else gcc_version))
+ print_verbose('Detected %sC compiler (CC=%s) version: %s' %
+ ('clang ' if is_clang else '', CC, version_str))
if not ok:
warn('failed to autodetect C compiler version (CC=%s)' % CC)
elif not is_clang and gcc_version < (4, 2, 0):