From 451321705864e1865b91722ee651b0a6b3b609bd Mon Sep 17 00:00:00 2001 From: Naoto Yamaguchi Date: Sat, 6 May 2023 12:18:41 +0900 Subject: Add support out of three image install to support agl demo ivi guests Existing AGL IC container integration build host and all guest using multi config. When we want to add support agl demo ivi guests, multiconfig based integration require to long build time by single build tree. This patch enable support out of tree image install to support. This method support prebuild ext4 image installation. This method realize to reduce build time for AGL IC developer. Bug-AGL: SPEC-4766 Change-Id: Id4ba092ce89c05bad3440e75845e6602bb0a50ab Signed-off-by: Naoto Yamaguchi --- .../agl-instrument-cluster-container-demo.bb | 2 -- .../images/agl-lxc-multi-partition-image.inc | 32 ++++++++++++++++++++++ 2 files changed, 32 insertions(+), 2 deletions(-) (limited to 'meta-agl-ic-container/recipes-platform') diff --git a/meta-agl-ic-container/recipes-platform/images/agl-instrument-cluster-container-demo.bb b/meta-agl-ic-container/recipes-platform/images/agl-instrument-cluster-container-demo.bb index 41f2df96..b83fd5e7 100644 --- a/meta-agl-ic-container/recipes-platform/images/agl-instrument-cluster-container-demo.bb +++ b/meta-agl-ic-container/recipes-platform/images/agl-instrument-cluster-container-demo.bb @@ -31,5 +31,3 @@ IMAGE_INSTALL += " \ # network manager to use VIRTUAL-RUNTIME_net_manager = "systemd" - -WKS_FILES:prepend = "agl-ic-container-noloader.wks " diff --git a/meta-agl-ic-container/recipes-platform/images/agl-lxc-multi-partition-image.inc b/meta-agl-ic-container/recipes-platform/images/agl-lxc-multi-partition-image.inc index bd85e70e..6531e9b9 100644 --- a/meta-agl-ic-container/recipes-platform/images/agl-lxc-multi-partition-image.inc +++ b/meta-agl-ic-container/recipes-platform/images/agl-lxc-multi-partition-image.inc @@ -2,6 +2,21 @@ require recipes-platform/images/agl-lxc-multiconfig-build.inc +# Install out of tree build image support +OUT_OF_TREE_CONTAINER_IMAGE_DEPLOY_DIR ??= "non" + +OUT_OF_TREE_CONTAINER_IMAGES ??= " \ + agl-ivi-demo-platform \ + agl-ivi-demo-platform-flutter \ + agl-ivi-demo-platform-html5 \ +" + +OUT_OF_TREE_CONTAINER_CONFIGS ??= " \ + cm-config-agl-qt-ivi-demo \ + cm-config-agl-flutter-ivi-demo \ + cm-config-agl-html5-ivi-demo \ +" + # Handle modification of IMAGE_LINK_NAME done by ULCB builds with Kingfisher support MACHINE_SUFFIX = "${@bb.utils.contains('AGL_FEATURES', 'kingfisher', '-kf', '', d)}" @@ -15,6 +30,23 @@ install_container_images() { bbnote "Installing ${src}" ln -s ${src} "${DEPLOY_DIR_IMAGE}/${image}.ext4" done + + if ${@bb.utils.contains('OUT_OF_TREE_CONTAINER_IMAGE_DEPLOY_DIR', 'non', 'false', 'true', d)}; then + for image in ${OUT_OF_TREE_CONTAINER_IMAGES}; do + rm -f "${DEPLOY_DIR_IMAGE}/${image}.ext4" + src="${OUT_OF_TREE_CONTAINER_IMAGE_DEPLOY_DIR}/images/${MACHINE}/${image}-${MACHINE}${MACHINE_SUFFIX}.ext4" + bbnote "Installing ${src}" + ln -s ${src} "${DEPLOY_DIR_IMAGE}/${image}.ext4" + done + fi } ROOTFS_POSTPROCESS_COMMAND += "install_container_images; " + +IMAGE_INSTALL:append = " \ + ${@bb.utils.contains('OUT_OF_TREE_CONTAINER_IMAGE_DEPLOY_DIR', 'non', '', '${OUT_OF_TREE_CONTAINER_CONFIGS}', d)} \ +" + +WKS_FILES:prepend = " \ + ${@bb.utils.contains('OUT_OF_TREE_CONTAINER_IMAGE_DEPLOY_DIR', 'non', 'agl-ic-container-noloader.wks ', 'agl-ic-container-noloader-demo.wks ', d)} \ +" -- cgit 1.2.3-korg