public inbox for isar-users@googlegroups.com
 help / color / mirror / Atom feed
* [PATCH 1/3] Revert "prefix DTB files with PN in deploy dir"
@ 2026-04-23 12:19 Zhihang Wei
  2026-04-23 12:19 ` [PATCH 2/3] doc: Restore API-CHANGELOG entry for artifacts naming and path changes Zhihang Wei
  2026-04-23 12:19 ` [PATCH 3/3] testsuite: Disable test cases that may fail due to unresolved DTB conflicts Zhihang Wei
  0 siblings, 2 replies; 5+ messages in thread
From: Zhihang Wei @ 2026-04-23 12:19 UTC (permalink / raw)
  To: isar-users

This reverts commit 8c34bb25b800d2d0d32a5154f87252a199cd902e.

The approach of prefixing DTB filenames has proven difficult to adopt
for some downstream users. Additionally, a general solution is needed
not only for DTBs but also for other artifacts that could cause
conflicts in multiconfig builds. Therefore, the patch is reverted.

This revert may re-introduce the do_copy_boot_files error for
DTBs with identical names belonging to different multiconfig targets.

Signed-off-by: Zhihang Wei <wzh@ilbers.de>
---
 RECIPE-API-CHANGELOG.md                       | 20 -------------------
 meta/classes-recipe/image.bbclass             |  6 ++----
 meta/classes-recipe/imagetypes_wic.bbclass    |  2 +-
 .../wic/plugins/source/bootimg-efi-isar.py    |  3 +--
 4 files changed, 4 insertions(+), 27 deletions(-)

diff --git a/RECIPE-API-CHANGELOG.md b/RECIPE-API-CHANGELOG.md
index 856da5de..0e6a3172 100644
--- a/RECIPE-API-CHANGELOG.md
+++ b/RECIPE-API-CHANGELOG.md
@@ -981,23 +981,3 @@ fragment, this can be specified via adding `${S}/path/to/fragment.cfg` to
 `KERNEL_CONFIG_FRAGMENTS`. If a fragment was checked out into ${WORKDIR} as
 part of a repository, a tarball, or some other directory structure, just
 specify it relative to ${WORKDIR} in `KERNEL_CONFIG_FRAGMENTS`.
-
-Changes in next
----------------
-
-### Prefix DTB file names when deploying
-
-DTB files are now placed in the ${DEPLOY_DIR_IMAGE} with a prefix of
-${PN}-${DISTRO}. During wic imaging, the prefix is removed again, so no changes
-to downstream wks files are needed (i.e. `dtb=my-device-tree.dtb` is not
-affected by this change). Custom imaging plugins need to be adapted to this
-change by removing the prefix from the filename. For that, the variable
-DTB_PREFIX is exported as bitbake var into wic environment.
-
-This fixes errors when building different distros with the same machine,
-whereby previously the following error occured:
-
-do_copy_boot_files: The recipe isar-image-base is trying to install
-files into a shared area when those files already exists. It happens
-when some files have the same names (e.g., dtb files) for different
-distros.
diff --git a/meta/classes-recipe/image.bbclass b/meta/classes-recipe/image.bbclass
index 9b5dd23e..26a4ec06 100644
--- a/meta/classes-recipe/image.bbclass
+++ b/meta/classes-recipe/image.bbclass
@@ -379,8 +379,7 @@ EOF
 KERNEL_IMG = "${PP_DEPLOY}/${KERNEL_IMAGE}"
 INITRD_IMG = "${PP_DEPLOY}/${INITRD_DEPLOY_FILE}"
 # only one dtb file supported, pick the first
-DTB_PREFIX = "${PN}-${DISTRO}."
-DTB_IMG = "${PP_DEPLOY}/${DTB_PREFIX}${@os.path.basename((d.getVar('DTB_FILES').split() or [''])[0])}"
+DTB_IMG = "${PP_DEPLOY}/${@(d.getVar('DTB_FILES').split() or [''])[0]}"
 
 do_copy_boot_files[cleandirs] += "${DEPLOYDIR}"
 do_copy_boot_files[sstate-inputdirs] = "${DEPLOYDIR}"
@@ -403,8 +402,7 @@ do_copy_boot_files() {
             die "${file} not found"
         fi
 
-        dtb_name=$(basename "$dtb")
-        cp -f "$dtb" "${DEPLOYDIR}/${DTB_PREFIX}$dtb_name"
+        cp -f "$dtb" "${DEPLOYDIR}/"
     done
 }
 addtask copy_boot_files before do_rootfs_postprocess after do_rootfs_install
diff --git a/meta/classes-recipe/imagetypes_wic.bbclass b/meta/classes-recipe/imagetypes_wic.bbclass
index c0813223..dd6c501d 100644
--- a/meta/classes-recipe/imagetypes_wic.bbclass
+++ b/meta/classes-recipe/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 KERNEL_FILE MACHINE DTB_PREFIX"
+WICVARS += "DISTRO DISTRO_ARCH KERNEL_FILE MACHINE"
 
 python do_rootfs_wicenv () {
     wicvars = d.getVar('WICVARS')
diff --git a/meta/scripts/lib/wic/plugins/source/bootimg-efi-isar.py b/meta/scripts/lib/wic/plugins/source/bootimg-efi-isar.py
index 32b220fa..6bc78d42 100644
--- a/meta/scripts/lib/wic/plugins/source/bootimg-efi-isar.py
+++ b/meta/scripts/lib/wic/plugins/source/bootimg-efi-isar.py
@@ -57,8 +57,7 @@ class BootimgEFIPlugin(SourcePlugin):
         if dtb:
             if ';' in dtb:
                 raise WicError("Only one DTB supported, exiting")
-            dtb_file = "%s%s" % (get_bitbake_var("DTB_PREFIX"), dtb)
-            cp_cmd = "cp %s/%s %s/%s" % (bootimg_dir, dtb_file, hdddir, dtb)
+            cp_cmd = "cp %s/%s %s" % (bootimg_dir, dtb, hdddir)
             exec_cmd(cp_cmd, True)
 
     @classmethod
-- 
2.39.5

-- 
You received this message because you are subscribed to the Google Groups "isar-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to isar-users+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/isar-users/20260423121941.1704827-1-wzh%40ilbers.de.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PATCH 2/3] doc: Restore API-CHANGELOG entry for artifacts naming and path changes
  2026-04-23 12:19 [PATCH 1/3] Revert "prefix DTB files with PN in deploy dir" Zhihang Wei
@ 2026-04-23 12:19 ` Zhihang Wei
  2026-04-23 12:19 ` [PATCH 3/3] testsuite: Disable test cases that may fail due to unresolved DTB conflicts Zhihang Wei
  1 sibling, 0 replies; 5+ messages in thread
From: Zhihang Wei @ 2026-04-23 12:19 UTC (permalink / raw)
  To: isar-users

To keep it clear for users what API changes (13cb77dd) were introduced
in Isar v1.0 and subsequently reverted (79e10791), the API-CHANGELOG
is restored and updated.

Signed-off-by: Zhihang Wei <wzh@ilbers.de>
---
 RECIPE-API-CHANGELOG.md | 86 +++++++++++++++++++++++++++++++++++++++++
 1 file changed, 86 insertions(+)

diff --git a/RECIPE-API-CHANGELOG.md b/RECIPE-API-CHANGELOG.md
index 0e6a3172..659a03b0 100644
--- a/RECIPE-API-CHANGELOG.md
+++ b/RECIPE-API-CHANGELOG.md
@@ -981,3 +981,89 @@ fragment, this can be specified via adding `${S}/path/to/fragment.cfg` to
 `KERNEL_CONFIG_FRAGMENTS`. If a fragment was checked out into ${WORKDIR} as
 part of a repository, a tarball, or some other directory structure, just
 specify it relative to ${WORKDIR} in `KERNEL_CONFIG_FRAGMENTS`.
+
+### Change DEPLOY_DIR_IMAGE path and artifacts naming
+
+Change DEPLOY_DIR_IMAGE from ${DEPLOY_DIR}/images/${MACHINE} to
+${DEPLOY_DIR}/images/${MACHINE}/${DISTRO}-${IMAGE_PN}.
+
+When building different distros with the same machine the following
+error occurs:
+
+do_copy_boot_files: The recipe isar-image-base is trying to install
+files into a shared area when those files already exists. It happens
+when some files have the same names (e.g., dtb files) for different
+distros.
+
+To prevent such collisions, image artifacts are now deployed into a
+distro- and image-specific subdirectory.
+
+Additionally, artifact filenames have been shortened by removing the
+${DISTRO} and ${IMAGE_PN} prefix, since this information is now
+encoded in the directory path.
+
+Example 1: Build isar-image-base (phyboard-mira, debian-bookworm)
+Under "build/tmp/deploy/images/":
+Before:
+phyboard-mira/imx6q-phytec-mira-rdk-nand.dtb
+phyboard-mira/isar-image-base-debian-bookworm-phyboard-mira-initrd.img
+phyboard-mira/isar-image-base-debian-bookworm-phyboard-mira-vmlinuz
+phyboard-mira/isar-image-base-debian-bookworm-phyboard-mira.dpkg_status
+phyboard-mira/isar-image-base-debian-bookworm-phyboard-mira.ubi
+
+After:
+phyboard-mira/debian-bookworm-isar-image-base/imx6q-phytec-mira-rdk-nand.dtb
+phyboard-mira/debian-bookworm-isar-image-base/initrd.img
+phyboard-mira/debian-bookworm-isar-image-base/vmlinuz
+phyboard-mira/debian-bookworm-isar-image-base/phyboard-mira.dpkg_status
+phyboard-mira/debian-bookworm-isar-image-base/phyboard-mira.ubi
+
+Example 2: Build isar-image-ci (qemuamd64, debian-bookworm)
+Under "build/tmp/deploy/images/":
+Before:
+qemuamd64/isar-image-ci-debian-bookworm-qemuamd64-initrd.img
+qemuamd64/isar-image-ci-debian-bookworm-qemuamd64-vmlinuz
+qemuamd64/isar-image-ci-debian-bookworm-qemuamd64.dpkg_status
+qemuamd64/isar-image-ci-debian-bookworm-qemuamd64.manifest
+qemuamd64/isar-image-ci-debian-bookworm-qemuamd64.wic
+qemuamd64/isar-image-ci-debian-bookworm-qemuamd64.wic.bmap
+qemuamd64/isar-image-ci-debian-bookworm-qemuamd64.wic.manifest
+
+After:
+qemuamd64/debian-bookworm-isar-image-ci/initrd.img
+qemuamd64/debian-bookworm-isar-image-ci/vmlinuz
+qemuamd64/debian-bookworm-isar-image-ci/qemuamd64.dpkg_status
+qemuamd64/debian-bookworm-isar-image-ci/qemuamd64.manifest
+qemuamd64/debian-bookworm-isar-image-ci/qemuamd64.wic
+qemuamd64/debian-bookworm-isar-image-ci/qemuamd64.wic.bmap
+qemuamd64/debian-bookworm-isar-image-ci/qemuamd64.wic.manifest
+
+Artifacts that do not belong to a full image (e.g. isar-image-base,
+isar-image-ci) remain unchanged. For example, a customized initramfs
+built independently is not affected.
+
+This change affects the location and naming of build artifacts and must
+be taken into account by downstream users.
+
+Note that this approach differs from OpenEmbedded.
+
+OpenEmbedded typically avoids artifact collisions in multiconfig builds
+by using separate TMPDIRs per configuration, resulting in multiple
+build directories such as tmp-qemuarm64 and tmp-qemuarm64customized. In
+this model, artifacts with identical names but different contents do
+not cause conflicts because they reside in their own isolated build
+directories.
+
+If multiple configurations are intentionally configured to share the
+same TMPDIR in OpenEmbedded, conflicts may occur and are not handled by
+OE. Artifacts with the same name overwrite each other, leading to
+incorrect build results.
+
+Changes in next
+---------------
+
+### Revert "Change DEPLOY_DIR_IMAGE path and artifacts naming"
+
+The DEPLOY_DIR_IMAGE path and artifacts naming changes introduced in
+13cb77dd (included in Isar v1.0) have been reverted. Deployment paths
+and artifact names are the same as pre-v1.0.
-- 
2.39.5

-- 
You received this message because you are subscribed to the Google Groups "isar-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to isar-users+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/isar-users/20260423121941.1704827-2-wzh%40ilbers.de.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PATCH 3/3] testsuite: Disable test cases that may fail due to unresolved DTB conflicts
  2026-04-23 12:19 [PATCH 1/3] Revert "prefix DTB files with PN in deploy dir" Zhihang Wei
  2026-04-23 12:19 ` [PATCH 2/3] doc: Restore API-CHANGELOG entry for artifacts naming and path changes Zhihang Wei
@ 2026-04-23 12:19 ` Zhihang Wei
  2026-04-23 12:56   ` 'MOESSBAUER, Felix' via isar-users
  1 sibling, 1 reply; 5+ messages in thread
From: Zhihang Wei @ 2026-04-23 12:19 UTC (permalink / raw)
  To: isar-users

Since the patches resolving DTB deployment conflicts have been reverted,
disable the affected test cases until a proper fix is in place.

Signed-off-by: Zhihang Wei <wzh@ilbers.de>
---
 testsuite/citest.py | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/testsuite/citest.py b/testsuite/citest.py
index fc6ec24c..ac45165b 100755
--- a/testsuite/citest.py
+++ b/testsuite/citest.py
@@ -697,7 +697,10 @@ class DtbDeployTest(CIBaseTest):
         ]
 
         self.init()
-        self.perform_build_test(targets, image_install='')
+        try:
+            self.perform_build_test(targets, image_install='')
+        except exceptions.TestFail:
+            self.cancel('KFAIL')
 
     def test_dtb_deploy_images(self):
         """
@@ -709,7 +712,10 @@ class DtbDeployTest(CIBaseTest):
         ]
 
         self.init()
-        self.perform_build_test(targets, image_install='')
+        try:
+            self.perform_build_test(targets, image_install='')
+        except exceptions.TestFail:
+            self.cancel('KFAIL')
 
 
 class NoCrossTest(CIBaseTest):
-- 
2.39.5

-- 
You received this message because you are subscribed to the Google Groups "isar-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to isar-users+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/isar-users/20260423121941.1704827-3-wzh%40ilbers.de.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH 3/3] testsuite: Disable test cases that may fail due to unresolved DTB conflicts
  2026-04-23 12:19 ` [PATCH 3/3] testsuite: Disable test cases that may fail due to unresolved DTB conflicts Zhihang Wei
@ 2026-04-23 12:56   ` 'MOESSBAUER, Felix' via isar-users
  2026-04-23 13:20     ` Zhihang Wei
  0 siblings, 1 reply; 5+ messages in thread
From: 'MOESSBAUER, Felix' via isar-users @ 2026-04-23 12:56 UTC (permalink / raw)
  To: Zhihang Wei, isar-users

On Thu, 2026-04-23 at 14:19 +0200, Zhihang Wei wrote:
> Since the patches resolving DTB deployment conflicts have been reverted,
> disable the affected test cases until a proper fix is in place.

Hi, usually you would apply this commit first before reverting the
change. Otherwise you have commits in the middle that don't pass CI.

But that's a nitpick. Thanks for cleaning this up.

Felix

> 
> Signed-off-by: Zhihang Wei <wzh@ilbers.de>
> ---
>  testsuite/citest.py | 10 ++++++++--
>  1 file changed, 8 insertions(+), 2 deletions(-)
> 
> diff --git a/testsuite/citest.py b/testsuite/citest.py
> index fc6ec24c..ac45165b 100755
> --- a/testsuite/citest.py
> +++ b/testsuite/citest.py
> @@ -697,7 +697,10 @@ class DtbDeployTest(CIBaseTest):
>          ]
>  
>          self.init()
> -        self.perform_build_test(targets, image_install='')
> +        try:
> +            self.perform_build_test(targets, image_install='')
> +        except exceptions.TestFail:
> +            self.cancel('KFAIL')
>  
>      def test_dtb_deploy_images(self):
>          """
> @@ -709,7 +712,10 @@ class DtbDeployTest(CIBaseTest):
>          ]
>  
>          self.init()
> -        self.perform_build_test(targets, image_install='')
> +        try:
> +            self.perform_build_test(targets, image_install='')
> +        except exceptions.TestFail:
> +            self.cancel('KFAIL')
>  
>  
>  class NoCrossTest(CIBaseTest):
> -- 
> 2.39.5
> 
> -- 
> You received this message because you are subscribed to the Google Groups "isar-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to isar-users+unsubscribe@googlegroups.com.
> To view this discussion visit https://groups.google.com/d/msgid/isar-users/20260423121941.1704827-3-wzh%40ilbers.de.

-- 
You received this message because you are subscribed to the Google Groups "isar-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to isar-users+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/isar-users/c09eedb9583350341490db2cc832856ee447ef1a.camel%40siemens.com.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH 3/3] testsuite: Disable test cases that may fail due to unresolved DTB conflicts
  2026-04-23 12:56   ` 'MOESSBAUER, Felix' via isar-users
@ 2026-04-23 13:20     ` Zhihang Wei
  0 siblings, 0 replies; 5+ messages in thread
From: Zhihang Wei @ 2026-04-23 13:20 UTC (permalink / raw)
  To: MOESSBAUER, Felix, isar-users



On 4/23/26 14:56, MOESSBAUER, Felix wrote:
> On Thu, 2026-04-23 at 14:19 +0200, Zhihang Wei wrote:
>> Since the patches resolving DTB deployment conflicts have been reverted,
>> disable the affected test cases until a proper fix is in place.
> Hi, usually you would apply this commit first before reverting the
> change. Otherwise you have commits in the middle that don't pass CI.
>
> But that's a nitpick. Thanks for cleaning this up.
>
> Felix
>
Thanks. There may be other affected tests as well. I'll check on CI and
update together in v2.

Zhihang
>> Signed-off-by: Zhihang Wei <wzh@ilbers.de>
>> ---
>>   testsuite/citest.py | 10 ++++++++--
>>   1 file changed, 8 insertions(+), 2 deletions(-)
>>
>> diff --git a/testsuite/citest.py b/testsuite/citest.py
>> index fc6ec24c..ac45165b 100755
>> --- a/testsuite/citest.py
>> +++ b/testsuite/citest.py
>> @@ -697,7 +697,10 @@ class DtbDeployTest(CIBaseTest):
>>           ]
>>   
>>           self.init()
>> -        self.perform_build_test(targets, image_install='')
>> +        try:
>> +            self.perform_build_test(targets, image_install='')
>> +        except exceptions.TestFail:
>> +            self.cancel('KFAIL')
>>   
>>       def test_dtb_deploy_images(self):
>>           """
>> @@ -709,7 +712,10 @@ class DtbDeployTest(CIBaseTest):
>>           ]
>>   
>>           self.init()
>> -        self.perform_build_test(targets, image_install='')
>> +        try:
>> +            self.perform_build_test(targets, image_install='')
>> +        except exceptions.TestFail:
>> +            self.cancel('KFAIL')
>>   
>>   
>>   class NoCrossTest(CIBaseTest):
>> -- 
>> 2.39.5
>>
>> -- 
>> You received this message because you are subscribed to the Google Groups "isar-users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an email to isar-users+unsubscribe@googlegroups.com.
>> To view this discussion visit https://groups.google.com/d/msgid/isar-users/20260423121941.1704827-3-wzh%40ilbers.de.

-- 
You received this message because you are subscribed to the Google Groups "isar-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to isar-users+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/isar-users/ccba0341-4466-4877-b98a-b15011b3ea34%40ilbers.de.

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2026-04-23 13:20 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-04-23 12:19 [PATCH 1/3] Revert "prefix DTB files with PN in deploy dir" Zhihang Wei
2026-04-23 12:19 ` [PATCH 2/3] doc: Restore API-CHANGELOG entry for artifacts naming and path changes Zhihang Wei
2026-04-23 12:19 ` [PATCH 3/3] testsuite: Disable test cases that may fail due to unresolved DTB conflicts Zhihang Wei
2026-04-23 12:56   ` 'MOESSBAUER, Felix' via isar-users
2026-04-23 13:20     ` Zhihang Wei

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox