From: Gylstorff Quirin <quirin.gylstorff@siemens.com>
To: isar-users@googlegroups.com
Subject: Re: [PATCH] image.bbclass: copy dtbs into a deploydir/subdirectory based on the image name
Date: Thu, 28 Mar 2024 17:28:29 +0100 [thread overview]
Message-ID: <e026fb32-9f2e-4635-9ea6-71d236a9f2cc@siemens.com> (raw)
In-Reply-To: <DB3PR10MB690820CF3DD2DCA71D822AF1E63B2@DB3PR10MB6908.EURPRD10.PROD.OUTLOOK.COM>
On 3/28/24 8:54 AM, 'nicusor.huhulea@siemens.com' via isar-users wrote:
> This fixes the build failures detailed in the https://groups.google.com/g/isar-users/c/Va0Ue-ISYeA and
> https://groups.google.com/g/isar-users/c/PSGU_AcdPZ8
> This adds the MACHINE variable to WICVARS, hence the need to reflect this change in
> cip-core/scripts/lib/wic/plugins/source/efibootguard-boot.py
>
>
> Signed-off-by: Nicusor Huhulea <nicusor.huhulea@siemens.com>
>
> diff --git a/meta/classes/image.bbclass b/meta/classes/image.bbclass
> index 73f1d52c..9b98719b 100644
> --- a/meta/classes/image.bbclass
> +++ b/meta/classes/image.bbclass
> @@ -377,16 +377,19 @@ do_copy_boot_files() {
> fi
> fi
>
> - for file in ${DTB_FILES}; do
> - dtb="$(find '${IMAGE_ROOTFS}/usr/lib' -type f \
> - -iwholename '*linux-image-*/'${file} | head -1)"
> -
> - if [ -z "$dtb" -o ! -e "$dtb" ]; then
> - die "${file} not found"
> - fi
> + if [ -n "${DTB_FILES}" ]; then
> + mkdir -p "${DEPLOYDIR}/${IMAGE_FULLNAME}.dtbs"
> + for file in ${DTB_FILES}; do
> + dtb="$(find '${IMAGE_ROOTFS}/usr/lib' -type f \
> + -iwholename '*linux-image-*/'${file} | head -1)"
> +
> + if [ -z "$dtb" -o ! -e "$dtb" ]; then
> + die "${file} not found"
> + fi
>
> - cp -f "$dtb" "${DEPLOYDIR}/"
> - done
> + cp -f "$dtb" "${DEPLOYDIR}/${IMAGE_FULLNAME}.dtbs"
And what is if we have multi dtbs defined this will overwrite them all.
Quirin
> + done > + fi
> }
> addtask copy_boot_files before do_rootfs_postprocess after do_rootfs_install
>
> diff --git a/meta/classes/imagetypes_wic.bbclass b/meta/classes/imagetypes_wic.bbclass
> index bce881ed..f0f1c438 100644
> --- a/meta/classes/imagetypes_wic.bbclass
> +++ b/meta/classes/imagetypes_wic.bbclass
> @@ -107,7 +107,7 @@ WICVARS += "\
> ROOTFS_SIZE STAGING_DATADIR STAGING_DIR STAGING_LIBDIR TARGET_SYS TRANSLATED_TARGET_ARCH"
>
> # Isar specific vars used in our plugins
> -WICVARS += "DISTRO DISTRO_ARCH"
> +WICVARS += "DISTRO DISTRO_ARCH MACHINE"
>
> python do_rootfs_wicenv () {
> wicvars = d.getVar('WICVARS')
>
next prev parent reply other threads:[~2024-03-28 16:28 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-03-28 7:54 nicusor.huhulea
2024-03-28 16:28 ` Gylstorff Quirin [this message]
2024-03-28 16:31 ` Gylstorff Quirin
2024-03-28 17:53 ` Gylstorff Quirin
2024-03-28 19:05 ` nicusor.huhulea
2024-04-08 8:12 ` Gylstorff Quirin
2024-04-12 14:11 ` nicusor.huhulea
2024-04-15 13:11 ` nicusor.huhulea
2024-04-15 13:19 ` Jan Kiszka
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=e026fb32-9f2e-4635-9ea6-71d236a9f2cc@siemens.com \
--to=quirin.gylstorff@siemens.com \
--cc=isar-users@googlegroups.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox