diff options
author | Charles-Antoine Couret <charles-antoine.couret@mind.be> | 2020-03-26 21:09:49 +0100 |
---|---|---|
committer | Jeremy A. Puhlman <jpuhlman@mvista.com> | 2020-07-16 09:00:52 -0700 |
commit | 45108a95215cef9481128503c45b6d9029b0f7d6 (patch) | |
tree | 8cbce6639382b9f5d3448af17cf2efcfc6b5507c | |
parent | 4272436e44015c66fdff65825af411fdd16b26c4 (diff) | |
download | openembedded-core-contrib-45108a95215cef9481128503c45b6d9029b0f7d6.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.
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>
-rw-r--r-- | meta/lib/oe/utils.py | 2 |
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): except subprocess.CalledProcessError as e: bb.fatal("Error running %s --version: %s" % (compiler, e.output.decode("utf-8"))) - match = re.match(".* (\d\.\d)\.\d.*", output.split('\n')[0]) + match = re.match(r".* (\d+\.\d+)\.\d+.*", output.split('\n')[0]) if not match: bb.fatal("Can't get compiler version from %s --version output" % compiler) |