diff options
| author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2022-03-16 17:45:29 +0000 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2022-03-17 16:44:33 +0000 |
| commit | da0cb26c00bc684d78ef2ea6d5a74c37992c66dd (patch) | |
| tree | 48e7c7cbeebcc1474eb1bf44a2cb8802c5f67a46 /meta/recipes-devtools/rust | |
| parent | b792bcd6021cd50e4bb4cc4a24fbee4cec055bc5 (diff) | |
| download | poky-da0cb26c00bc684d78ef2ea6d5a74c37992c66dd.tar.gz | |
rust-cross: Add rust-crosssdk variant for nativesdk use
Allow nativesdk recipes to find a correct version of the rust cross
compiler.
(From OE-Core rev: 0f5d26772abfbbae9096fa43901d8620f76aea3c)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/rust')
| -rw-r--r-- | meta/recipes-devtools/rust/rust-cross.inc | 7 | ||||
| -rw-r--r-- | meta/recipes-devtools/rust/rust-cross_1.59.0.bb | 6 | ||||
| -rw-r--r-- | meta/recipes-devtools/rust/rust-crosssdk_1.59.0.bb | 8 |
3 files changed, 14 insertions, 7 deletions
diff --git a/meta/recipes-devtools/rust/rust-cross.inc b/meta/recipes-devtools/rust/rust-cross.inc index a77f7d5122..f6babfeeda 100644 --- a/meta/recipes-devtools/rust/rust-cross.inc +++ b/meta/recipes-devtools/rust/rust-cross.inc | |||
| @@ -1,6 +1,3 @@ | |||
| 1 | require rust.inc | ||
| 2 | inherit cross | ||
| 3 | |||
| 4 | python do_rust_gen_targets () { | 1 | python do_rust_gen_targets () { |
| 5 | wd = d.getVar('WORKDIR') + '/targets/' | 2 | wd = d.getVar('WORKDIR') + '/targets/' |
| 6 | # It is important 'TARGET' is last here so that it overrides our less | 3 | # It is important 'TARGET' is last here so that it overrides our less |
| @@ -30,12 +27,8 @@ INHIBIT_DEFAULT_RUST_DEPS = "1" | |||
| 30 | # so it might make sense to take it's mapping. For now, though, we just mention | 27 | # so it might make sense to take it's mapping. For now, though, we just mention |
| 31 | # the bits we need explicitly. | 28 | # the bits we need explicitly. |
| 32 | DEPENDS += "rust-llvm-native" | 29 | DEPENDS += "rust-llvm-native" |
| 33 | DEPENDS += "virtual/${TARGET_PREFIX}gcc virtual/${TARGET_PREFIX}compilerlibs virtual/libc" | ||
| 34 | DEPENDS += "rust-native" | 30 | DEPENDS += "rust-native" |
| 35 | 31 | ||
| 36 | PROVIDES = "virtual/${TARGET_PREFIX}rust" | ||
| 37 | PN = "rust-cross-${TUNE_PKGARCH}-${TCLIBC}" | ||
| 38 | |||
| 39 | # In the cross compilation case, rustc doesn't seem to get the rpath quite | 32 | # In the cross compilation case, rustc doesn't seem to get the rpath quite |
| 40 | # right. It manages to include '../../lib/${TARGET_PREFIX}', but doesn't | 33 | # right. It manages to include '../../lib/${TARGET_PREFIX}', but doesn't |
| 41 | # include the '../../lib' (ie: relative path from cross_bindir to normal | 34 | # include the '../../lib' (ie: relative path from cross_bindir to normal |
diff --git a/meta/recipes-devtools/rust/rust-cross_1.59.0.bb b/meta/recipes-devtools/rust/rust-cross_1.59.0.bb index 3179d395d2..5358d98da8 100644 --- a/meta/recipes-devtools/rust/rust-cross_1.59.0.bb +++ b/meta/recipes-devtools/rust/rust-cross_1.59.0.bb | |||
| @@ -1,2 +1,8 @@ | |||
| 1 | require rust.inc | ||
| 2 | inherit cross | ||
| 1 | require rust-cross.inc | 3 | require rust-cross.inc |
| 2 | require rust-source.inc | 4 | require rust-source.inc |
| 5 | |||
| 6 | DEPENDS += "virtual/${TARGET_PREFIX}gcc virtual/${TARGET_PREFIX}compilerlibs virtual/libc" | ||
| 7 | PROVIDES = "virtual/${TARGET_PREFIX}rust" | ||
| 8 | PN = "rust-cross-${TUNE_PKGARCH}-${TCLIBC}" | ||
diff --git a/meta/recipes-devtools/rust/rust-crosssdk_1.59.0.bb b/meta/recipes-devtools/rust/rust-crosssdk_1.59.0.bb new file mode 100644 index 0000000000..5929978591 --- /dev/null +++ b/meta/recipes-devtools/rust/rust-crosssdk_1.59.0.bb | |||
| @@ -0,0 +1,8 @@ | |||
| 1 | require rust.inc | ||
| 2 | inherit crosssdk | ||
| 3 | require rust-cross.inc | ||
| 4 | require rust-source.inc | ||
| 5 | |||
| 6 | DEPENDS += "virtual/${TARGET_PREFIX}gcc-crosssdk virtual/nativesdk-${TARGET_PREFIX}compilerlibs virtual/nativesdk-libc" | ||
| 7 | PROVIDES = "virtual/nativesdk-${TARGET_PREFIX}rust" | ||
| 8 | PN = "rust-crosssdk-${TUNE_PKGARCH}-${TCLIBC}" | ||
