diff mbox series

[meta-lts-mixins,wrynose/rust,03/11] classes/ptest-cargo: add explanatory comment

Message ID 4ec6c97276ef2f91e3f2b0a41dd43c7be0e93dd5.1789155804.git.scott.murray@konsulko.com
State New
Headers show
Series Update to 1.98.1 | expand

Commit Message

Scott Murray Sept. 11, 2026, 8:15 p.m. UTC
From: Ross Burton <ross.burton@arm.com>

Add a comment to avoid someone else in the future wasting their time by
having the the idea of stripping the cargo hash from the test binary
filenames.

Some packages, notably librsvg, build multiple tests with the same base
name that are differentiated by the hash:

  primitives-3fd9d71b0a55e20a
  reference-00d9b406d910a645
  render_crash-c88a2b880ba97e09
  rsvg_convert-b43bd2236753f43d
  rsvg_convert-eef250e6c0174413
  rsvg_convert-f70976dd6cda88b0
  rsvg-eec8e799568381a3

Signed-off-by: Ross Burton <ross.burton@arm.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
(adapted from oe-core commit c40a156f543789dc570c5cbbe0ea8c1b48e5af32)
Signed-off-by: Scott Murray <scott.murray@konsulko.com>
---
 classes-recipe/ptest-cargo.bbclass | 2 ++
 1 file changed, 2 insertions(+)
diff mbox series

Patch

diff --git a/classes-recipe/ptest-cargo.bbclass b/classes-recipe/ptest-cargo.bbclass
index f4c881c..2e008b3 100644
--- a/classes-recipe/ptest-cargo.bbclass
+++ b/classes-recipe/ptest-cargo.bbclass
@@ -95,6 +95,8 @@  python do_install_ptest_cargo() {
 
     test_paths = []
     for test_bin in test_bins:
+        # Note that we can't strip the hash from the filename as some packages
+        # (eg librsvg) have multiple binaries with the same prefix.
         shutil.copy2(test_bin, ptest_dir)
         test_paths.append(os.path.join(ptest_path, os.path.basename(test_bin)))