diff options
| author | Hiroshi Hatake <hatake@clear-code.com> | 2019-12-16 17:41:45 +0900 |
|---|---|---|
| committer | Khem Raj <raj.khem@gmail.com> | 2019-12-16 09:40:41 -0800 |
| commit | be7a567a8eab50e6a0a10b3409850ddd0d529a6f (patch) | |
| tree | 0d1cdeec3db628b2d15dc0167a667c79a2b1ef69 /recipes-devtools/clang/clang.inc | |
| parent | bfd6f33325d4fe1ae0680d55d0ce5ff95533bbe2 (diff) | |
| download | meta-clang-be7a567a8eab50e6a0a10b3409850ddd0d529a6f.tar.gz | |
Compute LLVM_LIBDIR_SUFFIX correctly on multiarch environment
Co-authored-by: INAJIMA Daisuke <inajima@soum.co.jp>
Diffstat (limited to 'recipes-devtools/clang/clang.inc')
| -rw-r--r-- | recipes-devtools/clang/clang.inc | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/recipes-devtools/clang/clang.inc b/recipes-devtools/clang/clang.inc index 4c028b4..b631c0e4 100644 --- a/recipes-devtools/clang/clang.inc +++ b/recipes-devtools/clang/clang.inc | |||
| @@ -18,4 +18,22 @@ CLANGMD5SUM = "ff42885ed2ab98f1ecb8c1fc41205343" | |||
| 18 | LLDMD5SUM = "ae7dc7c027b1fa89b5b013d391d3ee2b" | 18 | LLDMD5SUM = "ae7dc7c027b1fa89b5b013d391d3ee2b" |
| 19 | LLDBMD5SUM = "2e0d44968471fcde980034dbb826bea9" | 19 | LLDBMD5SUM = "2e0d44968471fcde980034dbb826bea9" |
| 20 | 20 | ||
| 21 | def get_libdir_suffix(d, arch_var): | ||
| 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 | |||
| 37 | LLVM_LIBDIR_SUFFIX="${@get_libdir_suffix(d, 'TARGET_ARCH')}" | ||
| 38 | |||
| 21 | require common.inc | 39 | require common.inc |
