Skip to contentSkip to conversation

kernel.bbclass: Fix the do_strip() malfunction

PATCH New Kevin Hao 1 participant 1 message Apr 11, 2022

lore
Share & tools
lore

Kevin Hao

author
#0 lore raw

PATCH 1/1 kernel.bbclass: Fix the do_strip() malfunction

The BB variable can't be referenced directly in a python function, this misusage of the variable reference causes strip function to be always skipped.

Fixed: b9c3db4953e4 ("kernel.bbclass: Use KERNEL_IMAGEDEST instead of hardcoded boot path")

---
 meta/classes/kernel.bbclass | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/classes/kernel.bbclass +1 -1
index 7ca847f0a341..bc52419e0945 100644
@@ -711,7 +711,7 @@ python do_strip() {
     extra_sections = d.getVar('KERNEL_IMAGE_STRIP_EXTRA_SECTIONS')
     kernel_image = d.getVar('B') + "/" + d.getVar('KERNEL_OUTPUT_DIR') + "/vmlinux"
 
-    if (extra_sections and kernel_image.find('${KERNEL_IMAGEDEST}/vmlinux') != -1):
+    if (extra_sections and kernel_image.find(d.getVar('KERNEL_IMAGEDEST') + '/vmlinux') != -1):
         kernel_image_stripped = kernel_image + ".stripped"
         shutil.copy2(kernel_image, kernel_image_stripped)
         oe.package.runstrip((kernel_image_stripped, 8, strip, extra_sections))
Signature · 1 line
2.34.1