Skip to contentSkip to conversation

image_types.bbclass: add WIC_CREATE_EXTRA_ARGS

PATCH In review Christopher Larson 2 participants 3 messages May 3, 2016

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 image_types.bbclass: add WIC_CREATE_EXTRA_ARGS

From: Christopher Larson <[email protected]>

This'll be of use to pass things like --bmap.

---
 meta/classes/image_types.bbclass | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
meta/classes/image_types.bbclass +3 -1
index 19f89f3..385d47e 100644
@@ -193,6 +193,8 @@ def wks_search(files, search_path):
             if searched:
                 return searched
 
+WIC_CREATE_EXTRA_ARGS ?= ""
+
 IMAGE_CMD_wic () {
 	out="${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}"
 	wks="${WKS_FULL_PATH}"
@@ -200,7 +202,7 @@ IMAGE_CMD_wic () {
 		bbfatal "No kickstart files from WKS_FILES were found: ${WKS_FILES}. Please set WKS_FILE or WKS_FILES appropriately."
 	fi
 
-	BUILDDIR="${TOPDIR}" wic create "$wks" --vars "${STAGING_DIR_TARGET}/imgdata/" -e "${IMAGE_BASENAME}" -o "$out/"
+	BUILDDIR="${TOPDIR}" wic create "$wks" --vars "${STAGING_DIR_TARGET}/imgdata/" -e "${IMAGE_BASENAME}" -o "$out/" ${WIC_CREATE_EXTRA_ARGS}
 	mv "$out/build/$(basename "${wks%.wks}")"*.direct "$out${IMAGE_NAME_SUFFIX}.wic"
 	rm -rf "$out/"
 }
Signature · 1 line
2.8.0
#1 lore raw

Hi Christopher,

Thank you for the patch! I like the idea.

Would you mind adding or modifying wic oe-selftest to cover this?

PS: You've mentioned --bmap as a possible use case scenario for this. I don't think this is the case as it's simpler to use wic.bmap image type to achieve this. It's implemented by this patchset:
http://lists.openembedded.org/pipermail/openembedded-core/2016-April/120644.html

Quoted 39 lines · Christopher Larson

From: Christopher Larson <[email protected]>

This'll be of use to pass things like --bmap.

---
 meta/classes/image_types.bbclass | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
meta/classes/image_types.bbclass +3 -1
index 19f89f3..385d47e 100644
@@ -193,6 +193,8 @@ def wks_search(files, search_path):
             if searched:
                 return searched
 
+WIC_CREATE_EXTRA_ARGS ?= ""
+
 IMAGE_CMD_wic () {
 	out="${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}"
 	wks="${WKS_FULL_PATH}"
@@ -200,7 +202,7 @@ IMAGE_CMD_wic () {
 		bbfatal "No kickstart files from WKS_FILES were found: ${WKS_FILES}. Please set WKS_FILE or WKS_FILES appropriately."
 	fi
 
-	BUILDDIR="${TOPDIR}" wic create "$wks" --vars "${STAGING_DIR_TARGET}/imgdata/" -e "${IMAGE_BASENAME}" -o "$out/"
+	BUILDDIR="${TOPDIR}" wic create "$wks" --vars "${STAGING_DIR_TARGET}/imgdata/" -e "${IMAGE_BASENAME}" -o "$out/" ${WIC_CREATE_EXTRA_ARGS}
 	mv "$out/build/$(basename "${wks%.wks}")"*.direct "$out${IMAGE_NAME_SUFFIX}.wic"
 	rm -rf "$out/"
 }
Signature · 7 lines
2.8.0

-- 
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core
Signature · 3 lines
--
Regards,
Ed
#2 lore raw
Quoted 6 lines · Ed Bartosh

Hi Christopher,

Thank you for the patch! I like the idea.

Would you mind adding or modifying wic oe-selftest to cover this?

Quoted 8 lines

PS: You've mentioned --bmap as a possible use case scenario for this. I don't think this is the case as it's simpler to use wic.bmap image type to achieve this. It's implemented by this patchset:

http://lists.openembedded.org/pipermail/openembedded-core/2016-April/120644.html

Ah! Thanks. Will do. Thanks for the feedback.

Signature · 5 lines
Christopher Larson
kergoth at gmail dot com
Founder - BitBake, OpenEmbedded, OpenZaurus
Maintainer - Tslib
Senior Software Engineer, Mentor Graphics