diff options
author | Jack Lloyd <[email protected]> | 2019-01-04 12:23:33 -0500 |
---|---|---|
committer | Jack Lloyd <[email protected]> | 2019-01-04 12:23:33 -0500 |
commit | 3578f8c503a93611a596681613201a3b692c26a1 (patch) | |
tree | 2434bc8c1eab01d76ca39b97838fc854647d7dee /configure.py | |
parent | a95c67a5a1fd8c9afd9cb69770cb1542f558f163 (diff) |
Better output when we can't identify the compiler by macro
Diffstat (limited to 'configure.py')
-rwxr-xr-x | configure.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/configure.py b/configure.py index bf5151dee..fc9a0ba2b 100755 --- a/configure.py +++ b/configure.py @@ -2963,6 +2963,8 @@ def calculate_cc_min_version(options, ccinfo, source_paths): 'xlc': r'^ *XLC ([0-9]+) ([0-9]+)$', } + unknown_pattern = r'UNKNOWN 0 0' + if ccinfo.basename not in version_patterns: logging.info("No compiler version detection available for %s" % (ccinfo.basename)) return "0.0" @@ -2971,6 +2973,10 @@ def calculate_cc_min_version(options, ccinfo, source_paths): cc_output = run_compiler_preproc(options, ccinfo, detect_version_source, "0.0") + if re.search(unknown_pattern, cc_output) is not None: + logging.warning('Failed to get version for %s from macro check' % (ccinfo.basename)) + return "0.0" + match = re.search(version_patterns[ccinfo.basename], cc_output, flags=re.MULTILINE) if match is None: logging.warning("Tried to get %s version, but output '%s' does not match expected version format" % ( |