diff options
| author | Ranjitsinh Rathod <ranjitsinh.rathod@kpit.com> | 2024-08-01 18:24:41 +0530 |
|---|---|---|
| committer | Steve Sakoman <steve@sakoman.com> | 2024-08-06 19:11:18 -0700 |
| commit | 6ced2e7ca3b58130154035ad61685cd222909680 (patch) | |
| tree | 90d4be9ba2fa66ba28144d3a8fac42d65f2f0048 /meta/recipes-devtools/rust | |
| parent | bcbc1ad07a2bd6ce48a9996160a7e05082bd9ad8 (diff) | |
| download | poky-6ced2e7ca3b58130154035ad61685cd222909680.tar.gz | |
rust: Add new varaible RUST_ENABLE_EXTRA_TOOLS
There is a need to enable some extra tools from the rust for the build
and so this new variable will help for that
This varaible then we can use during do_configure task to add overall
values as per json format in build -> tools
(From OE-Core rev: 136a25567499191b23a4d000a06bf83a473224ca)
Signed-off-by: Ranjitsinh Rathod <ranjitsinh.rathod@kpit.com>
Signed-off-by: Steve Sakoman <steve@sakoman.com>
Diffstat (limited to 'meta/recipes-devtools/rust')
| -rw-r--r-- | meta/recipes-devtools/rust/rust_1.75.0.bb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/meta/recipes-devtools/rust/rust_1.75.0.bb b/meta/recipes-devtools/rust/rust_1.75.0.bb index 76e1fe2d84..c33f31d261 100644 --- a/meta/recipes-devtools/rust/rust_1.75.0.bb +++ b/meta/recipes-devtools/rust/rust_1.75.0.bb | |||
| @@ -70,6 +70,10 @@ addtask do_test_compile after do_configure do_rust_gen_targets | |||
| 70 | do_rust_setup_snapshot[dirs] += "${WORKDIR}/rust-snapshot" | 70 | do_rust_setup_snapshot[dirs] += "${WORKDIR}/rust-snapshot" |
| 71 | do_rust_setup_snapshot[vardepsexclude] += "UNINATIVE_LOADER" | 71 | do_rust_setup_snapshot[vardepsexclude] += "UNINATIVE_LOADER" |
| 72 | 72 | ||
| 73 | # there is a need to enable some more rust tools for the project | ||
| 74 | # We can extend a list of more tools via this variable | ||
| 75 | RUST_ENABLE_EXTRA_TOOLS ?= "rust-demangler" | ||
| 76 | |||
| 73 | python do_configure() { | 77 | python do_configure() { |
| 74 | import json | 78 | import json |
| 75 | import configparser | 79 | import configparser |
| @@ -141,7 +145,7 @@ python do_configure() { | |||
| 141 | config.add_section("build") | 145 | config.add_section("build") |
| 142 | config.set("build", "submodules", e(False)) | 146 | config.set("build", "submodules", e(False)) |
| 143 | config.set("build", "docs", e(False)) | 147 | config.set("build", "docs", e(False)) |
| 144 | config.set("build", "tools", ["rust-demangler",]) | 148 | config.set("build", "tools", e(d.getVar("RUST_ENABLE_EXTRA_TOOLS").split())) |
| 145 | 149 | ||
| 146 | rustc = d.expand("${WORKDIR}/rust-snapshot/bin/rustc") | 150 | rustc = d.expand("${WORKDIR}/rust-snapshot/bin/rustc") |
| 147 | config.set("build", "rustc", e(rustc)) | 151 | config.set("build", "rustc", e(rustc)) |
