diff options
| author | Peter Marko <peter.marko@siemens.com> | 2024-06-25 21:36:45 +0200 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2024-06-27 13:03:34 +0100 |
| commit | 7afa4f50b49dd3eed809b2e66ca18cc86835c534 (patch) | |
| tree | ff5f3cabd25e1c782ad1cfcae40346da77d16287 /meta/classes-recipe/ptest-cargo.bbclass | |
| parent | 918c66d8e6dfb605055a447efa82755a70a47b00 (diff) | |
| download | poky-7afa4f50b49dd3eed809b2e66ca18cc86835c534.tar.gz | |
cargo: remove True option to getVar calls
Layer cleanup similar to
https://git.openembedded.org/openembedded-core/commit/?id=26c74fd10614582e177437608908eb43688ab510
(From OE-Core rev: 9a2ed52473a3e4eb662509824ef8e59520ebdefb)
Signed-off-by: Peter Marko <peter.marko@siemens.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes-recipe/ptest-cargo.bbclass')
| -rw-r--r-- | meta/classes-recipe/ptest-cargo.bbclass | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/meta/classes-recipe/ptest-cargo.bbclass b/meta/classes-recipe/ptest-cargo.bbclass index c46df362bf..fd1df9d7c9 100644 --- a/meta/classes-recipe/ptest-cargo.bbclass +++ b/meta/classes-recipe/ptest-cargo.bbclass | |||
| @@ -12,10 +12,10 @@ python do_compile_ptest_cargo() { | |||
| 12 | import subprocess | 12 | import subprocess |
| 13 | import json | 13 | import json |
| 14 | 14 | ||
| 15 | cargo = bb.utils.which(d.getVar("PATH"), d.getVar("CARGO", True)) | 15 | cargo = bb.utils.which(d.getVar("PATH"), d.getVar("CARGO")) |
| 16 | cargo_build_flags = d.getVar("CARGO_BUILD_FLAGS", True) | 16 | cargo_build_flags = d.getVar("CARGO_BUILD_FLAGS") |
| 17 | rust_flags = d.getVar("RUSTFLAGS", True) | 17 | rust_flags = d.getVar("RUSTFLAGS") |
| 18 | manifest_path = d.getVar("CARGO_MANIFEST_PATH", True) | 18 | manifest_path = d.getVar("CARGO_MANIFEST_PATH") |
| 19 | project_manifest_path = os.path.normpath(manifest_path) | 19 | project_manifest_path = os.path.normpath(manifest_path) |
| 20 | manifest_dir = os.path.dirname(manifest_path) | 20 | manifest_dir = os.path.dirname(manifest_path) |
| 21 | 21 | ||
| @@ -66,7 +66,7 @@ python do_compile_ptest_cargo() { | |||
| 66 | if not test_bins: | 66 | if not test_bins: |
| 67 | bb.fatal("Unable to find any test binaries") | 67 | bb.fatal("Unable to find any test binaries") |
| 68 | 68 | ||
| 69 | cargo_test_binaries_file = d.getVar('CARGO_TEST_BINARIES_FILES', True) | 69 | cargo_test_binaries_file = d.getVar('CARGO_TEST_BINARIES_FILES') |
| 70 | bb.note(f"Found {len(test_bins)} tests, write their paths into {cargo_test_binaries_file}") | 70 | bb.note(f"Found {len(test_bins)} tests, write their paths into {cargo_test_binaries_file}") |
| 71 | with open(cargo_test_binaries_file, "w") as f: | 71 | with open(cargo_test_binaries_file, "w") as f: |
| 72 | for test_bin in test_bins: | 72 | for test_bin in test_bins: |
| @@ -77,10 +77,10 @@ python do_compile_ptest_cargo() { | |||
| 77 | python do_install_ptest_cargo() { | 77 | python do_install_ptest_cargo() { |
| 78 | import shutil | 78 | import shutil |
| 79 | 79 | ||
| 80 | dest_dir = d.getVar("D", True) | 80 | dest_dir = d.getVar("D") |
| 81 | pn = d.getVar("PN", True) | 81 | pn = d.getVar("PN") |
| 82 | ptest_path = d.getVar("PTEST_PATH", True) | 82 | ptest_path = d.getVar("PTEST_PATH") |
| 83 | cargo_test_binaries_file = d.getVar('CARGO_TEST_BINARIES_FILES', True) | 83 | cargo_test_binaries_file = d.getVar('CARGO_TEST_BINARIES_FILES') |
| 84 | rust_test_args = d.getVar('RUST_TEST_ARGS') or "" | 84 | rust_test_args = d.getVar('RUST_TEST_ARGS') or "" |
| 85 | 85 | ||
| 86 | ptest_dir = os.path.join(dest_dir, ptest_path.lstrip('/')) | 86 | ptest_dir = os.path.join(dest_dir, ptest_path.lstrip('/')) |
