Skip to contentSkip to conversation

image.bbclass: Only append to IMAGE_LINK_NAME if it was already set

PATCH New Mike Crowe 1 participant 1 message Jul 9, 2019

lore
Share & tools
lore

Mike Crowe

author
#0 lore raw

PATCH 1/1 image.bbclass: Only append to IMAGE_LINK_NAME if it was already set

create_symlinks does not create any links if IMAGE_LINK_NAME is empty. Unfortunately, setup_debugfs_variables unconditionally appends '-dbg' which results in a previously-empty IMAGE_LINK_NAME containing just '-dbg'. Let's check that it's not empty before appending.

---
 meta/classes/image.bbclass | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
meta/classes/image.bbclass +2 -1
index 7daa97effb..682858dc95 100644
@@ -328,7 +328,8 @@ addtask do_image_qa_setscene
 
 def setup_debugfs_variables(d):
     d.appendVar('IMAGE_ROOTFS', '-dbg')
-    d.appendVar('IMAGE_LINK_NAME', '-dbg')
+    if d.getVar('IMAGE_LINK_NAME'):
+        d.appendVar('IMAGE_LINK_NAME', '-dbg')
     d.appendVar('IMAGE_NAME','-dbg')
     d.setVar('IMAGE_BUILDING_DEBUGFS', 'true')
     debugfs_image_fstypes = d.getVar('IMAGE_FSTYPES_DEBUGFS')
Signature · 1 line
2.20.1