summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel McGregor <daniel.mcgregor@vecima.com>2020-01-23 09:40:31 -0600
committerKhem Raj <raj.khem@gmail.com>2020-01-24 09:15:46 -0800
commit98a9122637041b92fc40459bf71ad8d067bc4270 (patch)
treebd1e1af9bb31dffe982ae9f9cb611a921ebfc107
parent606c8a8ecac566177fef8659ee8b7e5d0cfd8962 (diff)
downloadmeta-clang-98a9122637041b92fc40459bf71ad8d067bc4270.tar.gz
Use simplier libdir suffix computation
An earlier commit added a suffix table to determine the libdir suffix for multilib targets. This table failed at least in the lib32 case for x86, where the suffix should have been '', but was instead '32'. Use the same method as the cmake bbclass instead. Signed-off-by: Daniel McGregor <daniel.mcgregor@vecima.com>
-rw-r--r--recipes-devtools/clang/clang.inc18
1 files changed, 1 insertions, 17 deletions
diff --git a/recipes-devtools/clang/clang.inc b/recipes-devtools/clang/clang.inc
index 3fd0723..84e692d 100644
--- a/recipes-devtools/clang/clang.inc
+++ b/recipes-devtools/clang/clang.inc
@@ -18,22 +18,6 @@ CLANGMD5SUM = "ff42885ed2ab98f1ecb8c1fc41205343"
18LLDMD5SUM = "ae7dc7c027b1fa89b5b013d391d3ee2b" 18LLDMD5SUM = "ae7dc7c027b1fa89b5b013d391d3ee2b"
19LLDBMD5SUM = "2e0d44968471fcde980034dbb826bea9" 19LLDBMD5SUM = "2e0d44968471fcde980034dbb826bea9"
20 20
21def get_libdir_suffix(d, arch_var): 21LLVM_LIBDIR_SUFFIX="${@d.getVar('baselib').replace('lib', '')}"
22 import re
23 multilibs = (d.getVar("MULTILIB_VARIANTS") or "").split()
24 if multilibs:
25 a = d.getVar(arch_var, True)
26 if re.match('(i.86|athlon)$', a): return '32'
27 elif re.match('x86.64$', a): return '64'
28 elif re.match('(arm|armbe)$', a): return '32'
29 elif re.match('(aarch64|aarch64_be)$', a): return '64'
30 elif re.match('mips(isa|)32(r6|)(el|)$', a): return '32'
31 elif re.match('mips(isa|)64(r6|)(el|)$', a): return '64'
32 elif re.match('p(pc|owerpc)', a): return '32'
33 elif re.match('p(pc|owerpc)64', a): return '64'
34 else:
35 return ''
36
37LLVM_LIBDIR_SUFFIX="${@get_libdir_suffix(d, 'TARGET_ARCH')}"
38 22
39require common.inc 23require common.inc