mirror of https://gitlab.com/ita1024/waf.git
Issue 1372 version detection for old and buggy sun compilers
This commit is contained in:
parent
067ade9a40
commit
dcd6184d3f
|
@ -1153,7 +1153,11 @@ def get_suncc_version(conf, cc):
|
|||
try:
|
||||
out, err = conf.cmd_and_log(cmd, output=0)
|
||||
except Errors.WafError:
|
||||
conf.fatal('Could not find suncc %r' % cmd)
|
||||
# Older versions of the compiler exit with non-zero status when reporting their version
|
||||
if not (hasattr(e, 'returncode') and hasattr(e, 'stdout') and hasattr(e, 'stderr')):
|
||||
conf.fatal('Could not find suncc %r' % cmd)
|
||||
out = e.stdout
|
||||
err = e.stderr
|
||||
|
||||
version = (out or err)
|
||||
version = version.split('\n')[0]
|
||||
|
|
Loading…
Reference in New Issue