summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--recipes-core/openjdk/openjdk-8-common.inc6
1 files changed, 6 insertions, 0 deletions
diff --git a/recipes-core/openjdk/openjdk-8-common.inc b/recipes-core/openjdk/openjdk-8-common.inc
index 83828e1..070ffaa 100644
--- a/recipes-core/openjdk/openjdk-8-common.inc
+++ b/recipes-core/openjdk/openjdk-8-common.inc
@@ -232,6 +232,8 @@ FLAGS_GCC7 = "-fno-lifetime-dse -fno-delete-null-pointer-checks"
232# version. 232# version.
233 233
234def version_specific_cflags(d): 234def version_specific_cflags(d):
235 import re
236
235 extraflags = None 237 extraflags = None
236 version = None 238 version = None
237 239
@@ -246,6 +248,10 @@ def version_specific_cflags(d):
246 # work if the native toolchain is Clang, but as of this writing that 248 # work if the native toolchain is Clang, but as of this writing that
247 # doesn't work anyway. 249 # doesn't work anyway.
248 version = d.getVar('GCCVERSION', expand=True)[0] 250 version = d.getVar('GCCVERSION', expand=True)[0]
251 # skip non digit characters at the beginning, e.g. from "linaro-6.2%"
252 match = re.search("\d", version)
253 if match:
254 version = version[match.start():]
249 255
250 if version.isdigit(): 256 if version.isdigit():
251 extraflags = d.getVar('FLAGS_GCC%d' % int(version), True) or '' 257 extraflags = d.getVar('FLAGS_GCC%d' % int(version), True) or ''