diff options
| -rw-r--r-- | meta/recipes-devtools/rust/rust-common.inc | 6 | ||||
| -rw-r--r-- | meta/recipes-devtools/rust/rust-cross.inc | 7 |
2 files changed, 7 insertions, 6 deletions
diff --git a/meta/recipes-devtools/rust/rust-common.inc b/meta/recipes-devtools/rust/rust-common.inc index 37abd2cd26..82ff03b908 100644 --- a/meta/recipes-devtools/rust/rust-common.inc +++ b/meta/recipes-devtools/rust/rust-common.inc | |||
| @@ -297,6 +297,12 @@ def rust_gen_target(d, thing, wd, features, cpu, arch, abi=""): | |||
| 297 | sys = sys_for(d, thing) | 297 | sys = sys_for(d, thing) |
| 298 | prefix = prefix_for(d, thing) | 298 | prefix = prefix_for(d, thing) |
| 299 | 299 | ||
| 300 | if thing == "TARGET": | ||
| 301 | abi = d.getVar('ABIEXTENSION') | ||
| 302 | # arm and armv7 have different targets in llvm | ||
| 303 | if arch == "arm" and target_is_armv7(d): | ||
| 304 | arch = 'armv7' | ||
| 305 | |||
| 300 | rust_arch = oe.rust.arch_to_rust_arch(arch) | 306 | rust_arch = oe.rust.arch_to_rust_arch(arch) |
| 301 | 307 | ||
| 302 | if abi: | 308 | if abi: |
diff --git a/meta/recipes-devtools/rust/rust-cross.inc b/meta/recipes-devtools/rust/rust-cross.inc index f6babfeeda..4c026b1f38 100644 --- a/meta/recipes-devtools/rust/rust-cross.inc +++ b/meta/recipes-devtools/rust/rust-cross.inc | |||
| @@ -8,15 +8,10 @@ python do_rust_gen_targets () { | |||
| 8 | features = "" | 8 | features = "" |
| 9 | cpu = "generic" | 9 | cpu = "generic" |
| 10 | arch = d.getVar('{}_ARCH'.format(thing)) | 10 | arch = d.getVar('{}_ARCH'.format(thing)) |
| 11 | abi = "" | ||
| 12 | if thing is "TARGET": | 11 | if thing is "TARGET": |
| 13 | abi = d.getVar('ABIEXTENSION') | ||
| 14 | # arm and armv7 have different targets in llvm | ||
| 15 | if arch == "arm" and target_is_armv7(d): | ||
| 16 | arch = 'armv7' | ||
| 17 | features = d.getVar('TARGET_LLVM_FEATURES') or "" | 12 | features = d.getVar('TARGET_LLVM_FEATURES') or "" |
| 18 | cpu = d.getVar('TARGET_LLVM_CPU') | 13 | cpu = d.getVar('TARGET_LLVM_CPU') |
| 19 | rust_gen_target(d, thing, wd, features, cpu, arch, abi) | 14 | rust_gen_target(d, thing, wd, features, cpu, arch) |
| 20 | } | 15 | } |
| 21 | 16 | ||
| 22 | # Otherwise we'll depend on what we provide | 17 | # Otherwise we'll depend on what we provide |
