2
0
mirror of https://gitlab.com/ita1024/waf.git synced 2025-01-25 18:00:03 +01:00

Detect newer sun compilers Issue 1686

This commit is contained in:
Thomas Nagy 2016-01-16 21:13:38 +01:00
parent 5b0e88adeb
commit 101dc83283

View File

@ -1147,7 +1147,9 @@ def get_suncc_version(conf, cc):
version = (out or err)
version = version.splitlines()[0]
version_re = re.compile(r'cc:\s+sun\s+(c\+\+|c)\s+(?P<major>\d*)\.(?P<minor>\d*)', re.I).search
# cc: Sun C 5.10 SunOS_i386 2009/06/03
# cc: Studio 12.5 Sun C++ 5.14 SunOS_sparc Beta 2015/11/17
version_re = re.compile(r'cc: (studio.*?|\s+)?sun\s+(c\+\+|c)\s+(?P<major>\d*)\.(?P<minor>\d*)', re.I).search
match = version_re(version)
if match:
k = match.groupdict()