summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCharles-Antoine Couret <charles-antoine.couret@mind.be>2020-03-26 21:09:49 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2020-09-16 13:35:09 +0100
commit08c38828916071c58cc7316ce5bd7e923d71e179 (patch)
tree5ac0c75ff4d87208942f0795119afba7c0db2af4
parent7b515c6df507847447b0c2f32bc2fa41cd030907 (diff)
downloadpoky-08c38828916071c58cc7316ce5bd7e923d71e179.tar.gz
utils: fix gcc 10 version detection
Utils can not detect GCC 10 correctly due to wrong regex. It generates this error "ERROR: Can't get compiler version from gcc --version output" Sub-version numbers should be 1 or more digits instead of 1 only. (From OE-Core rev: 1d6f50a5e58f46f8af6e83c4e288d93a717187ea) (From OE-Core rev: e73228e6b039bd972d36774bfb360a638a03d821) Signed-off-by: Charles-Antoine Couret <charles-antoine.couret@mind.be> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 186fe4a3d390a52b87282c3e694ce3251e45ee78) Signed-off-by: Jeremy A. Puhlman <jpuhlman@mvista.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/lib/oe/utils.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/meta/lib/oe/utils.py b/meta/lib/oe/utils.py
index 8a584d6ddd..96ebc36b8b 100644
--- a/meta/lib/oe/utils.py
+++ b/meta/lib/oe/utils.py
@@ -370,7 +370,7 @@ def host_gcc_version(d, taskcontextonly=False):
370 except subprocess.CalledProcessError as e: 370 except subprocess.CalledProcessError as e:
371 bb.fatal("Error running %s --version: %s" % (compiler, e.output.decode("utf-8"))) 371 bb.fatal("Error running %s --version: %s" % (compiler, e.output.decode("utf-8")))
372 372
373 match = re.match(".* (\d\.\d)\.\d.*", output.split('\n')[0]) 373 match = re.match(r".* (\d+\.\d+)\.\d+.*", output.split('\n')[0])
374 if not match: 374 if not match:
375 bb.fatal("Can't get compiler version from %s --version output" % compiler) 375 bb.fatal("Can't get compiler version from %s --version output" % compiler)
376 376