diff options
| author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2022-08-10 21:46:19 +0100 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2022-08-12 11:46:26 +0100 |
| commit | 83e7f668ae6b697bfb89eaee80609bd8d509ba71 (patch) | |
| tree | 9be2365800400a2b44c8a7c68cbf08a7627c4285 | |
| parent | 883aea9b6e02f796d11d46f5c2a82ea620c19797 (diff) | |
| download | poky-83e7f668ae6b697bfb89eaee80609bd8d509ba71.tar.gz | |
rust: Remove unneeded RUST_TARGETGENS settings
These match the default from the class so drop them. We then always
generate all targets so remove the configuration from the class.
(From OE-Core rev: e4d56256936c55bab2bf2934ccbde9157ef7dc57)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
| -rw-r--r-- | meta/classes/rust-target-config.bbclass | 8 | ||||
| -rw-r--r-- | meta/recipes-devtools/cargo/cargo.inc | 2 | ||||
| -rw-r--r-- | meta/recipes-devtools/rust/libstd-rs.inc | 3 | ||||
| -rw-r--r-- | meta/recipes-devtools/rust/rust.inc | 2 |
4 files changed, 2 insertions, 13 deletions
diff --git a/meta/classes/rust-target-config.bbclass b/meta/classes/rust-target-config.bbclass index 0f0797603e..135ed86308 100644 --- a/meta/classes/rust-target-config.bbclass +++ b/meta/classes/rust-target-config.bbclass | |||
| @@ -372,16 +372,12 @@ do_rust_gen_targets[vardeps] += "DATA_LAYOUT TARGET_ENDIAN TARGET_POINTER_WIDTH | |||
| 372 | RUST_TARGETS_DIR = "${WORKDIR}/rust-targets/" | 372 | RUST_TARGETS_DIR = "${WORKDIR}/rust-targets/" |
| 373 | export RUST_TARGET_PATH = "${RUST_TARGETS_DIR}" | 373 | export RUST_TARGET_PATH = "${RUST_TARGETS_DIR}" |
| 374 | 374 | ||
| 375 | RUST_TARGETGENS = "BUILD HOST TARGET" | ||
| 376 | |||
| 377 | python do_rust_gen_targets () { | 375 | python do_rust_gen_targets () { |
| 378 | wd = d.getVar('RUST_TARGETS_DIR') | 376 | wd = d.getVar('RUST_TARGETS_DIR') |
| 379 | # Order of BUILD, HOST, TARGET is important in case the files overwrite, most specific last | 377 | # Order of BUILD, HOST, TARGET is important in case the files overwrite, most specific last |
| 380 | rust_gen_target(d, 'BUILD', wd, d.getVar('BUILD_ARCH')) | 378 | rust_gen_target(d, 'BUILD', wd, d.getVar('BUILD_ARCH')) |
| 381 | if "HOST" in d.getVar("RUST_TARGETGENS"): | 379 | rust_gen_target(d, 'HOST', wd, d.getVar('HOST_ARCH')) |
| 382 | rust_gen_target(d, 'HOST', wd, d.getVar('HOST_ARCH')) | 380 | rust_gen_target(d, 'TARGET', wd, d.getVar('TARGET_ARCH')) |
| 383 | if "TARGET" in d.getVar("RUST_TARGETGENS"): | ||
| 384 | rust_gen_target(d, 'TARGET', wd, d.getVar('TARGET_ARCH')) | ||
| 385 | } | 381 | } |
| 386 | 382 | ||
| 387 | addtask rust_gen_targets after do_patch before do_compile | 383 | addtask rust_gen_targets after do_patch before do_compile |
diff --git a/meta/recipes-devtools/cargo/cargo.inc b/meta/recipes-devtools/cargo/cargo.inc index 636e9c4fe5..40421df4f7 100644 --- a/meta/recipes-devtools/cargo/cargo.inc +++ b/meta/recipes-devtools/cargo/cargo.inc | |||
| @@ -18,8 +18,6 @@ EXCLUDE_FROM_WORLD = "1" | |||
| 18 | 18 | ||
| 19 | inherit cargo pkgconfig | 19 | inherit cargo pkgconfig |
| 20 | 20 | ||
| 21 | RUST_TARGETGENS = "BUILD HOST TARGET" | ||
| 22 | |||
| 23 | do_cargo_setup_snapshot () { | 21 | do_cargo_setup_snapshot () { |
| 24 | ${WORKDIR}/rust-snapshot-components/${CARGO_SNAPSHOT}/install.sh --prefix="${WORKDIR}/${CARGO_SNAPSHOT}" --disable-ldconfig | 22 | ${WORKDIR}/rust-snapshot-components/${CARGO_SNAPSHOT}/install.sh --prefix="${WORKDIR}/${CARGO_SNAPSHOT}" --disable-ldconfig |
| 25 | # Need to use uninative's loader if enabled/present since the library paths | 23 | # Need to use uninative's loader if enabled/present since the library paths |
diff --git a/meta/recipes-devtools/rust/libstd-rs.inc b/meta/recipes-devtools/rust/libstd-rs.inc index 1498b88f0e..d49383ced5 100644 --- a/meta/recipes-devtools/rust/libstd-rs.inc +++ b/meta/recipes-devtools/rust/libstd-rs.inc | |||
| @@ -12,9 +12,6 @@ DEPENDS:append:libc-musl = " libunwind" | |||
| 12 | DEPENDS:remove:riscv32 = "libunwind" | 12 | DEPENDS:remove:riscv32 = "libunwind" |
| 13 | DEPENDS:remove:riscv64 = "libunwind" | 13 | DEPENDS:remove:riscv64 = "libunwind" |
| 14 | 14 | ||
| 15 | |||
| 16 | RUST_TARGETGENS = "BUILD HOST TARGET" | ||
| 17 | |||
| 18 | # Embed bitcode in order to allow compiling both with and without LTO | 15 | # Embed bitcode in order to allow compiling both with and without LTO |
| 19 | RUSTFLAGS += "-Cembed-bitcode=yes" | 16 | RUSTFLAGS += "-Cembed-bitcode=yes" |
| 20 | # Needed so cargo can find libbacktrace | 17 | # Needed so cargo can find libbacktrace |
diff --git a/meta/recipes-devtools/rust/rust.inc b/meta/recipes-devtools/rust/rust.inc index 7e302b5992..284347dedc 100644 --- a/meta/recipes-devtools/rust/rust.inc +++ b/meta/recipes-devtools/rust/rust.inc | |||
| @@ -34,8 +34,6 @@ setup_cargo_environment () { | |||
| 34 | 34 | ||
| 35 | inherit rust-target-config | 35 | inherit rust-target-config |
| 36 | 36 | ||
| 37 | RUST_TARGETGENS = "BUILD HOST TARGET" | ||
| 38 | |||
| 39 | do_rust_setup_snapshot () { | 37 | do_rust_setup_snapshot () { |
| 40 | for installer in "${WORKDIR}/rust-snapshot-components/"*"/install.sh"; do | 38 | for installer in "${WORKDIR}/rust-snapshot-components/"*"/install.sh"; do |
| 41 | "${installer}" --prefix="${WORKDIR}/rust-snapshot" --disable-ldconfig | 39 | "${installer}" --prefix="${WORKDIR}/rust-snapshot" --disable-ldconfig |
