public inbox for isar-users@googlegroups.com
 help / color / mirror / Atom feed
* [PATCH] image: disable cache-deb-src for sid-ports
@ 2022-06-15 14:08 Anton Mikanovich
  2022-06-20 13:40 ` Anton Mikanovich
  0 siblings, 1 reply; 2+ messages in thread
From: Anton Mikanovich @ 2022-06-15 14:08 UTC (permalink / raw)
  To: isar-users; +Cc: Anton Mikanovich

Enabling 'cache-deb-src' in BASE_REPO_FEATURES for Debian Sid-Ports
targets sometimes fails with:

| E: Can not find version '1:13.0.1-4' of package 'llvm-toolchain-13'
| E: Unable to find a source package for llvm-toolchain-13
| WARNING: exit code 100 from a shell command.
| DEBUG: Python function do_rootfs_postprocess finished
| ERROR: ExecutionError('isar-image-base-qemuriscv64/1.0-r0/temp/run.cache_deb_src.2245792', 100, None, None)
ERROR: Task (mc:qemuriscv64-sid-ports:isar-image-base.bb:do_rootfs_postprocess) failed with exit code '1'

This happens when deb and deb-src repos (different for Sid-Ports) are
going out of sync on package version update. To prevent such failures
disable cache-deb-src on Sid-Ports targets.

Signed-off-by: Anton Mikanovich <amikan@ilbers.de>
---
 meta/classes/image.bbclass | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/meta/classes/image.bbclass b/meta/classes/image.bbclass
index 0da56b7..ee9b5ed 100644
--- a/meta/classes/image.bbclass
+++ b/meta/classes/image.bbclass
@@ -42,6 +42,17 @@ python(){
         bb.warn("IMAGE_TRANSIENT_PACKAGES is set and no longer supported")
     if (d.getVar('IMAGE_TYPE')):
         bb.warn("IMAGE_TYPE is deprecated, please switch to IMAGE_FSTYPES")
+
+    # Debian Sid-Ports stores deb and deb-src in separate repos, which fails
+    # sometimes on fetching sources if repos are not in sync during packages
+    # version update. It makes Isar to fail on cache-deb-src, so disable it.
+    base_repo_features = d.getVar('BASE_REPO_FEATURES') or ""
+    feature_list = base_repo_features.split()
+    if ('cache-deb-src' in feature_list):
+        if (d.getVar('DISTRO') == 'debian-sid-ports'):
+            bb.warn("BASE_REPO_FEATURES for debian-sid-ports is not supported, disabling")
+            feature_list.remove("cache-deb-src")
+            d.setVar('BASE_REPO_FEATURES', ' '.join(feature_list))
 }
 
 def cfg_script(d):
-- 
2.30.2


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

* Re: [PATCH] image: disable cache-deb-src for sid-ports
  2022-06-15 14:08 [PATCH] image: disable cache-deb-src for sid-ports Anton Mikanovich
@ 2022-06-20 13:40 ` Anton Mikanovich
  0 siblings, 0 replies; 2+ messages in thread
From: Anton Mikanovich @ 2022-06-20 13:40 UTC (permalink / raw)
  To: isar-users

15.06.2022 17:08, Anton Mikanovich wrote:
> Enabling 'cache-deb-src' in BASE_REPO_FEATURES for Debian Sid-Ports
> targets sometimes fails with:
>
> | E: Can not find version '1:13.0.1-4' of package 'llvm-toolchain-13'
> | E: Unable to find a source package for llvm-toolchain-13
> | WARNING: exit code 100 from a shell command.
> | DEBUG: Python function do_rootfs_postprocess finished
> | ERROR: ExecutionError('isar-image-base-qemuriscv64/1.0-r0/temp/run.cache_deb_src.2245792', 100, None, None)
> ERROR: Task (mc:qemuriscv64-sid-ports:isar-image-base.bb:do_rootfs_postprocess) failed with exit code '1'
>
> This happens when deb and deb-src repos (different for Sid-Ports) are
> going out of sync on package version update. To prevent such failures
> disable cache-deb-src on Sid-Ports targets.
>
> Signed-off-by: Anton Mikanovich <amikan@ilbers.de>
Applied to next.

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

end of thread, other threads:[~2022-06-20 13:40 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-06-15 14:08 [PATCH] image: disable cache-deb-src for sid-ports Anton Mikanovich
2022-06-20 13:40 ` Anton Mikanovich

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