* [PATCH v2 0/3] Fixes for complex multiarch dependency propagation
@ 2026-07-30 11:19 'Felix Moessbauer' via isar-users
2026-07-30 11:19 ` [PATCH v2 1/3] fix(rootfs): copy isar-apt packages instead of downloading 'Felix Moessbauer' via isar-users
` (4 more replies)
0 siblings, 5 replies; 6+ messages in thread
From: 'Felix Moessbauer' via isar-users @ 2026-07-30 11:19 UTC (permalink / raw)
To: isar-users; +Cc: jan.kiszka, akarpovich, Felix Moessbauer
The corresponding errors have been spotted on the xenomai-images layer [1].
For details, see the individual commits.
This series has been tested on fast CI.
[1] https://source.denx.de/Xenomai/xenomai-images
Changes since v1:
- add missing signed-off to p2
- no functional changes
Best regards,
Felix Moessbauer
Siemens AG
Felix Moessbauer (3):
fix(rootfs): copy isar-apt packages instead of downloading
fix: redirect archall dependency to native provider on non cross
builds
testsuite: check propagation of archall to deps on native
.../recipes-app/test-all-depnative/files/rules | 11 +++++++++++
.../test-all-depnative/test-all-depnative.bb | 13 +++++++++++++
meta/classes-recipe/multiarch.bbclass | 6 +++++-
meta/classes-recipe/rootfs.bbclass | 16 ++++------------
testsuite/citest.py | 13 +++++++++++++
5 files changed, 46 insertions(+), 13 deletions(-)
create mode 100644 meta-test/recipes-app/test-all-depnative/files/rules
create mode 100644 meta-test/recipes-app/test-all-depnative/test-all-depnative.bb
--
2.53.0
--
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/20260730111933.1237145-1-felix.moessbauer%40siemens.com.
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH v2 1/3] fix(rootfs): copy isar-apt packages instead of downloading
2026-07-30 11:19 [PATCH v2 0/3] Fixes for complex multiarch dependency propagation 'Felix Moessbauer' via isar-users
@ 2026-07-30 11:19 ` 'Felix Moessbauer' via isar-users
2026-07-30 11:19 ` [PATCH v2 2/3] fix: redirect archall dependency to native provider on non cross builds 'Felix Moessbauer' via isar-users
` (3 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: 'Felix Moessbauer' via isar-users @ 2026-07-30 11:19 UTC (permalink / raw)
To: isar-users; +Cc: jan.kiszka, akarpovich, Felix Moessbauer
Previously, the arch part was stripped, hence on multiarch or compat
scenarios the wrong package might have been downloaded. We fix this by
considering the whole filename. For that, we switch to cp, as we
otherwise would have to reconstruct the package name from the filename.
As the whole path is urlencoded, we cannot directly pass the url to cp.
Instead, we reconstruct it based on the base-path (which is taken as-is,
as it does not have any special characters) and the second field emitted
on --print-uris, which provides the decoded filename.
As we now use cp, we also don't need any locking anymore (technically we
did not need it before either, but apt was called in a way that required
it).
Fixes: b90b722f ("rootfs: Deny packages download during install")
Signed-off-by: Felix Moessbauer <felix.moessbauer@siemens.com>
---
meta/classes-recipe/rootfs.bbclass | 16 ++++------------
1 file changed, 4 insertions(+), 12 deletions(-)
diff --git a/meta/classes-recipe/rootfs.bbclass b/meta/classes-recipe/rootfs.bbclass
index 77e6aefc..2ce8cee3 100644
--- a/meta/classes-recipe/rootfs.bbclass
+++ b/meta/classes-recipe/rootfs.bbclass
@@ -361,23 +361,15 @@ ROOTFS_INSTALL_COMMAND += "rootfs_install_pkgs_isar_download"
rootfs_install_pkgs_isar_download[weight] = "50"
rootfs_install_pkgs_isar_download[isar-apt-lock] = "acquire-before release-after"
rootfs_install_pkgs_isar_download() {
- mkdir -p "${WORKDIR}/dpkg"
-
- # Use our own dpkg lock files rather than those in the rootfs since we are not root
- # (this is safe as there are no concurrent apt/dpkg operations for that rootfs)
- touch "${WORKDIR}/dpkg/lock" "${WORKDIR}/dpkg/lock-frontend"
-
# Command apt-get install do not cache packages from local repos
# We can obtain non cached package URIs by recalling install command here
- # No need in export those files to dl_dir, so we can run it right after
+ # No need to export those files to dl_dir, so we can run it right after
rootfs_cmd --bind "${ROOTFSDIR}/var/cache/apt/archives" /var/cache/apt/archives \
- --bind "${WORKDIR}/dpkg/lock" /var/lib/dpkg/lock \
- --bind "${WORKDIR}/dpkg/lock-frontend" /var/lib/dpkg/lock-frontend \
--chdir "/var/cache/apt/archives" \
${ROOTFSDIR} \
- -- /usr/bin/sh -c "apt-get ${ROOTFS_APT_ARGS} --print-uris ${ROOTFS_PACKAGES} | \
- sed -n \"s|^.*/\\(.*\\)_[^_]*_[^_]*\\.deb'.*|\\1|p\" | \
- xargs -r apt-get download"
+ -- /usr/bin/sh -c 'apt-get ${ROOTFS_APT_ARGS} --print-uris ${ROOTFS_PACKAGES} | \
+ sed -n "s|^.file:\(/[^'\'']*/\)[^'\'']*\.deb. \([^ ]*\.deb\) .*|\1\2|p" | \
+ while read -r path; do cp -n "$path" ./ ; done'
}
ROOTFS_INSTALL_COMMAND += "${@ 'rootfs_install_clean_files' if (d.getVar('ROOTFS_CLEAN_FILES') or '').strip() else ''}"
--
2.53.0
--
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/20260730111933.1237145-2-felix.moessbauer%40siemens.com.
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH v2 2/3] fix: redirect archall dependency to native provider on non cross builds
2026-07-30 11:19 [PATCH v2 0/3] Fixes for complex multiarch dependency propagation 'Felix Moessbauer' via isar-users
2026-07-30 11:19 ` [PATCH v2 1/3] fix(rootfs): copy isar-apt packages instead of downloading 'Felix Moessbauer' via isar-users
@ 2026-07-30 11:19 ` 'Felix Moessbauer' via isar-users
2026-07-30 11:19 ` [PATCH v2 3/3] testsuite: check propagation of archall to deps on native 'Felix Moessbauer' via isar-users
` (2 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: 'Felix Moessbauer' via isar-users @ 2026-07-30 11:19 UTC (permalink / raw)
To: isar-users; +Cc: jan.kiszka, akarpovich, Felix Moessbauer
The extend_provides needs to mirror the -archall pattern from fixup_depends:
when a provide ends in -archall, the arch-independent (native-equivalent)
provider must be exposed under its bare name, not <name>-archall-native.
We change it so that for the native case it strips -archall and emits
the bare name
Fixes: 327fb313 ("sbuild: do not build arch all packages on cross")
Signed-off-by: Felix Moessbauer <felix.moessbauer@siemens.com>
---
meta/classes-recipe/multiarch.bbclass | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/meta/classes-recipe/multiarch.bbclass b/meta/classes-recipe/multiarch.bbclass
index 5f84fac2..a30d530c 100644
--- a/meta/classes-recipe/multiarch.bbclass
+++ b/meta/classes-recipe/multiarch.bbclass
@@ -16,7 +16,11 @@ python() {
if not pn_multiarch_target(pn):
all_provides = (d.getVar('PROVIDES') or '').split()
for p in all_provides:
- if not pn_multiarch_target(p):
+ if p.endswith('-archall'):
+ # arch=all provider: expose bare name for the native-equivalent
+ if provides == 'native':
+ d.appendVar('PROVIDES', ' ' + p[:-len('-archall')])
+ elif not pn_multiarch_target(p):
d.appendVar('PROVIDES', f' {p}-{provides}')
d.appendVar('PROVIDES', f' {pn}-{provides}')
--
2.53.0
--
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/20260730111933.1237145-3-felix.moessbauer%40siemens.com.
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH v2 3/3] testsuite: check propagation of archall to deps on native
2026-07-30 11:19 [PATCH v2 0/3] Fixes for complex multiarch dependency propagation 'Felix Moessbauer' via isar-users
2026-07-30 11:19 ` [PATCH v2 1/3] fix(rootfs): copy isar-apt packages instead of downloading 'Felix Moessbauer' via isar-users
2026-07-30 11:19 ` [PATCH v2 2/3] fix: redirect archall dependency to native provider on non cross builds 'Felix Moessbauer' via isar-users
@ 2026-07-30 11:19 ` 'Felix Moessbauer' via isar-users
2026-07-30 11:30 ` [PATCH v2 0/3] Fixes for complex multiarch dependency propagation 'Florian Bezdeka' via isar-users
2026-08-05 8:39 ` Zhihang Wei
4 siblings, 0 replies; 6+ messages in thread
From: 'Felix Moessbauer' via isar-users @ 2026-07-30 11:19 UTC (permalink / raw)
To: isar-users; +Cc: jan.kiszka, akarpovich, Felix Moessbauer
Signed-off-by: Felix Moessbauer <felix.moessbauer@siemens.com>
---
.../recipes-app/test-all-depnative/files/rules | 11 +++++++++++
.../test-all-depnative/test-all-depnative.bb | 13 +++++++++++++
testsuite/citest.py | 13 +++++++++++++
3 files changed, 37 insertions(+)
create mode 100644 meta-test/recipes-app/test-all-depnative/files/rules
create mode 100644 meta-test/recipes-app/test-all-depnative/test-all-depnative.bb
diff --git a/meta-test/recipes-app/test-all-depnative/files/rules b/meta-test/recipes-app/test-all-depnative/files/rules
new file mode 100644
index 00000000..6640cf23
--- /dev/null
+++ b/meta-test/recipes-app/test-all-depnative/files/rules
@@ -0,0 +1,11 @@
+#!/usr/bin/make -f
+%:
+ dh \$@
+
+# Detect cross-compilation and fail if so
+override_dh_auto_configure:
+ @if [ "$(DEB_BUILD_ARCH)" != "$(DEB_HOST_ARCH)" ]; then \
+ echo "Cross-compilation detected! This is an \"all\" package."; \
+ exit 1; \
+ fi
+ dh_auto_configure
diff --git a/meta-test/recipes-app/test-all-depnative/test-all-depnative.bb b/meta-test/recipes-app/test-all-depnative/test-all-depnative.bb
new file mode 100644
index 00000000..328d79f9
--- /dev/null
+++ b/meta-test/recipes-app/test-all-depnative/test-all-depnative.bb
@@ -0,0 +1,13 @@
+# Test all package depending on an arch=all package provided via -archall.
+
+SRC_URI = "file://rules"
+
+inherit dpkg-raw
+
+MAINTAINER = "isar-users <isar-users@googlegroups.com>"
+
+DEPENDS = "test-all-any-doc"
+
+do_install() {
+ bbnote "Test \"all\" package depending on an arch=all (-archall) package."
+}
diff --git a/testsuite/citest.py b/testsuite/citest.py
index a4f15d04..a600ade9 100644
--- a/testsuite/citest.py
+++ b/testsuite/citest.py
@@ -472,6 +472,19 @@ class CrossTest(CIBaseTest):
self.perform_build_test(targets, lines=lines,
image_install=image_install)
+ def test_native_dependencies(self):
+ targets = [
+ 'mc:qemuamd64-trixie:isar-image-ci',
+ ]
+
+ self.init()
+ image_install = 'test-all-depnative'
+ self.perform_build_test(
+ targets,
+ image_install=image_install,
+ bitbake_extra_args=["-c", "rootfs_install"]
+ )
+
def test_cross_riscv64(self):
"""
:avocado: tags=riscv64
--
2.53.0
--
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/20260730111933.1237145-4-felix.moessbauer%40siemens.com.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH v2 0/3] Fixes for complex multiarch dependency propagation
2026-07-30 11:19 [PATCH v2 0/3] Fixes for complex multiarch dependency propagation 'Felix Moessbauer' via isar-users
` (2 preceding siblings ...)
2026-07-30 11:19 ` [PATCH v2 3/3] testsuite: check propagation of archall to deps on native 'Felix Moessbauer' via isar-users
@ 2026-07-30 11:30 ` 'Florian Bezdeka' via isar-users
2026-08-05 8:39 ` Zhihang Wei
4 siblings, 0 replies; 6+ messages in thread
From: 'Florian Bezdeka' via isar-users @ 2026-07-30 11:30 UTC (permalink / raw)
To: Felix Moessbauer, isar-users; +Cc: jan.kiszka, akarpovich
On Thu, 2026-07-30 at 13:19 +0200, 'Felix Moessbauer' via isar-users
wrote:
> The corresponding errors have been spotted on the xenomai-images layer [1].
> For details, see the individual commits.
>
> This series has been tested on fast CI.
>
> [1] https://source.denx.de/Xenomai/xenomai-images
Seems this is working again, but the official URL meanwhile changed to
https://gitlab.com/Xenomai/xenomai-images
>
> Changes since v1:
>
> - add missing signed-off to p2
> - no functional changes
>
> Best regards,
> Felix Moessbauer
> Siemens AG
>
> Felix Moessbauer (3):
> fix(rootfs): copy isar-apt packages instead of downloading
> fix: redirect archall dependency to native provider on non cross
> builds
> testsuite: check propagation of archall to deps on native
>
> .../recipes-app/test-all-depnative/files/rules | 11 +++++++++++
> .../test-all-depnative/test-all-depnative.bb | 13 +++++++++++++
> meta/classes-recipe/multiarch.bbclass | 6 +++++-
> meta/classes-recipe/rootfs.bbclass | 16 ++++------------
> testsuite/citest.py | 13 +++++++++++++
> 5 files changed, 46 insertions(+), 13 deletions(-)
> create mode 100644 meta-test/recipes-app/test-all-depnative/files/rules
> create mode 100644 meta-test/recipes-app/test-all-depnative/test-all-depnative.bb
>
> --
> 2.53.0
>
> --
> 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/20260730111933.1237145-1-felix.moessbauer%40siemens.com.
--
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/5eb5a5d1da42e20d7a46fd08e8015bcfd995e75d.camel%40siemens.com.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH v2 0/3] Fixes for complex multiarch dependency propagation
2026-07-30 11:19 [PATCH v2 0/3] Fixes for complex multiarch dependency propagation 'Felix Moessbauer' via isar-users
` (3 preceding siblings ...)
2026-07-30 11:30 ` [PATCH v2 0/3] Fixes for complex multiarch dependency propagation 'Florian Bezdeka' via isar-users
@ 2026-08-05 8:39 ` Zhihang Wei
4 siblings, 0 replies; 6+ messages in thread
From: Zhihang Wei @ 2026-08-05 8:39 UTC (permalink / raw)
To: Felix Moessbauer, isar-users; +Cc: jan.kiszka, akarpovich
Applied to next, thanks.
Zhihang
On 7/30/26 13:19, 'Felix Moessbauer' via isar-users wrote:
> The corresponding errors have been spotted on the xenomai-images layer [1].
> For details, see the individual commits.
>
> This series has been tested on fast CI.
>
> [1] https://source.denx.de/Xenomai/xenomai-images
>
> Changes since v1:
>
> - add missing signed-off to p2
> - no functional changes
>
> Best regards,
> Felix Moessbauer
> Siemens AG
>
> Felix Moessbauer (3):
> fix(rootfs): copy isar-apt packages instead of downloading
> fix: redirect archall dependency to native provider on non cross
> builds
> testsuite: check propagation of archall to deps on native
>
> .../recipes-app/test-all-depnative/files/rules | 11 +++++++++++
> .../test-all-depnative/test-all-depnative.bb | 13 +++++++++++++
> meta/classes-recipe/multiarch.bbclass | 6 +++++-
> meta/classes-recipe/rootfs.bbclass | 16 ++++------------
> testsuite/citest.py | 13 +++++++++++++
> 5 files changed, 46 insertions(+), 13 deletions(-)
> create mode 100644 meta-test/recipes-app/test-all-depnative/files/rules
> create mode 100644 meta-test/recipes-app/test-all-depnative/test-all-depnative.bb
>
--
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/54881a2c-3727-419e-89fa-66a68317689a%40ilbers.de.
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2026-08-05 8:39 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-07-30 11:19 [PATCH v2 0/3] Fixes for complex multiarch dependency propagation 'Felix Moessbauer' via isar-users
2026-07-30 11:19 ` [PATCH v2 1/3] fix(rootfs): copy isar-apt packages instead of downloading 'Felix Moessbauer' via isar-users
2026-07-30 11:19 ` [PATCH v2 2/3] fix: redirect archall dependency to native provider on non cross builds 'Felix Moessbauer' via isar-users
2026-07-30 11:19 ` [PATCH v2 3/3] testsuite: check propagation of archall to deps on native 'Felix Moessbauer' via isar-users
2026-07-30 11:30 ` [PATCH v2 0/3] Fixes for complex multiarch dependency propagation 'Florian Bezdeka' via isar-users
2026-08-05 8:39 ` Zhihang Wei
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox