* [PATCH 1/2] do not add cross profile when building native package
@ 2025-11-03 16:01 'Felix Moessbauer' via isar-users
2025-11-03 16:01 ` [PATCH 2/2] propagate distro-specific dependencies of arch all packages 'Felix Moessbauer' via isar-users
` (2 more replies)
0 siblings, 3 replies; 5+ messages in thread
From: 'Felix Moessbauer' via isar-users @ 2025-11-03 16:01 UTC (permalink / raw)
To: isar-users
Cc: jan.kiszka, cedric.hombourger, Felix Moessbauer, Benedikt Niedermayr
When building a -native package, the cross profile must not be added as
otherwise stricter apt cache checks added in trixie trigger. It anyways
makes no sense to add the cross profile when BUILD_ARCH equals
PACKAGE_ARCH. Previously this check was implemented incorrectly, as the
build arch was compared to the DISTRO_ARCH, which is always the target
arch in isar terms. This resulted in the following error message in
sbuild:
E: The package cache was built for different architectures: amd64 vs arm64
W: You may want to run apt-get update to correct these problems
E: The package cache file is corrupted
E: apt-get dist-upgrade failed
On bookworm, the incorrect check remained unnoticed, as apt did not have
the stricter checks yet.
Fixes: 872ef2e3 ("dpkg-base: Fix enabling of cross build profile")
Tested-by: Benedikt Niedermayr <benedikt.niedermayr@siemens.com>
Signed-off-by: Felix Moessbauer <felix.moessbauer@siemens.com>
---
meta/classes/dpkg-base.bbclass | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/meta/classes/dpkg-base.bbclass b/meta/classes/dpkg-base.bbclass
index 4468a49a..d8287e8d 100644
--- a/meta/classes/dpkg-base.bbclass
+++ b/meta/classes/dpkg-base.bbclass
@@ -146,7 +146,7 @@ dpkg_runbuild() {
def isar_deb_build_profiles(d):
deb_build_profiles = d.getVar('DEB_BUILD_PROFILES')
- if d.getVar('BUILD_ARCH') != d.getVar('DISTRO_ARCH'):
+ if d.getVar('BUILD_ARCH') != d.getVar('PACKAGE_ARCH'):
deb_build_profiles += ' cross'
return deb_build_profiles.strip()
--
2.51.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/20251103160131.1005284-1-felix.moessbauer%40siemens.com.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH 2/2] propagate distro-specific dependencies of arch all packages
2025-11-03 16:01 [PATCH 1/2] do not add cross profile when building native package 'Felix Moessbauer' via isar-users
@ 2025-11-03 16:01 ` 'Felix Moessbauer' via isar-users
2025-11-03 16:05 ` [PATCH 1/2] do not add cross profile when building native package 'Jan Kiszka' via isar-users
2025-11-04 12:25 ` Zhihang Wei
2 siblings, 0 replies; 5+ messages in thread
From: 'Felix Moessbauer' via isar-users @ 2025-11-03 16:01 UTC (permalink / raw)
To: isar-users
Cc: jan.kiszka, cedric.hombourger, Felix Moessbauer, Benedikt Niedermayr
DPKG_ARCH=all packages are always build in their -native variant.
However, these packages still can have non-native dependencies which
must be built for the distro arch.
Fixes: 23a73895 ("multiarch: inject native variants of preferred providers")
Tested-by: Benedikt Niedermayr <benedikt.niedermayr@siemens.com>
Signed-off-by: Felix Moessbauer <felix.moessbauer@siemens.com>
---
meta/classes/multiarch.bbclass | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/meta/classes/multiarch.bbclass b/meta/classes/multiarch.bbclass
index c2bba21f..74b8f5b8 100644
--- a/meta/classes/multiarch.bbclass
+++ b/meta/classes/multiarch.bbclass
@@ -106,11 +106,13 @@ python multiarch_virtclass_handler() {
# Arch=all packages might build depend on other arch=all packages,
# hence we need to correctly model the dependency chain.
# We implement this by dispatching the non-native variant to the -native
- # variant by adding a dependency. We further replace the non-native
- # do_deploy_dep task with a noop to preserve the dependency chain.
+ # variant by adding a dependency. We further empty the non-native
+ # do_deploy_dep task and clear the internal dependency chain, but keep
+ # other attached variables like RDEPENDS to preserve the dependency chain.
e.data.setVar('do_deploy_deb', '')
- bb.build.deltask('deploy_deb', e.data)
- bb.build.addtask('deploy_deb', 'do_build', '', e.data)
+ # clear internal dependencies (e.g. to do_dpkg_build)
+ e.data.setVarFlag('do_deploy_deb', 'deps', [])
+ # dispatch to native variant
e.data.setVarFlag('do_deploy_deb', 'depends', f'{pn}-native:do_deploy_deb')
}
addhandler multiarch_virtclass_handler
--
2.51.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/20251103160131.1005284-2-felix.moessbauer%40siemens.com.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH 1/2] do not add cross profile when building native package
2025-11-03 16:01 [PATCH 1/2] do not add cross profile when building native package 'Felix Moessbauer' via isar-users
2025-11-03 16:01 ` [PATCH 2/2] propagate distro-specific dependencies of arch all packages 'Felix Moessbauer' via isar-users
@ 2025-11-03 16:05 ` 'Jan Kiszka' via isar-users
2025-11-04 12:25 ` Zhihang Wei
2 siblings, 0 replies; 5+ messages in thread
From: 'Jan Kiszka' via isar-users @ 2025-11-03 16:05 UTC (permalink / raw)
To: Felix Moessbauer, isar-users; +Cc: cedric.hombourger, Benedikt Niedermayr
On 03.11.25 17:01, Felix Moessbauer wrote:
> When building a -native package, the cross profile must not be added as
> otherwise stricter apt cache checks added in trixie trigger. It anyways
> makes no sense to add the cross profile when BUILD_ARCH equals
> PACKAGE_ARCH. Previously this check was implemented incorrectly, as the
> build arch was compared to the DISTRO_ARCH, which is always the target
> arch in isar terms. This resulted in the following error message in
> sbuild:
>
> E: The package cache was built for different architectures: amd64 vs arm64
> W: You may want to run apt-get update to correct these problems
> E: The package cache file is corrupted
> E: apt-get dist-upgrade failed
>
> On bookworm, the incorrect check remained unnoticed, as apt did not have
> the stricter checks yet.
>
> Fixes: 872ef2e3 ("dpkg-base: Fix enabling of cross build profile")
> Tested-by: Benedikt Niedermayr <benedikt.niedermayr@siemens.com>
> Signed-off-by: Felix Moessbauer <felix.moessbauer@siemens.com>
> ---
> meta/classes/dpkg-base.bbclass | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/meta/classes/dpkg-base.bbclass b/meta/classes/dpkg-base.bbclass
> index 4468a49a..d8287e8d 100644
> --- a/meta/classes/dpkg-base.bbclass
> +++ b/meta/classes/dpkg-base.bbclass
> @@ -146,7 +146,7 @@ dpkg_runbuild() {
>
> def isar_deb_build_profiles(d):
> deb_build_profiles = d.getVar('DEB_BUILD_PROFILES')
> - if d.getVar('BUILD_ARCH') != d.getVar('DISTRO_ARCH'):
> + if d.getVar('BUILD_ARCH') != d.getVar('PACKAGE_ARCH'):
> deb_build_profiles += ' cross'
> return deb_build_profiles.strip()
>
Tested here as well: Works, and this makes sense, indeed. Resolves
https://groups.google.com/g/isar-users/c/IUSoAfSF5OU/m/ZYPR34b9AAAJ.
Thanks,
Jan
--
Siemens AG, Foundational Technologies
Linux Expert Center
--
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/60d14dce-4ad9-40e7-b698-5f7f77a18d0d%40siemens.com.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH 1/2] do not add cross profile when building native package
2025-11-03 16:01 [PATCH 1/2] do not add cross profile when building native package 'Felix Moessbauer' via isar-users
2025-11-03 16:01 ` [PATCH 2/2] propagate distro-specific dependencies of arch all packages 'Felix Moessbauer' via isar-users
2025-11-03 16:05 ` [PATCH 1/2] do not add cross profile when building native package 'Jan Kiszka' via isar-users
@ 2025-11-04 12:25 ` Zhihang Wei
2025-11-04 14:20 ` 'MOESSBAUER, Felix' via isar-users
2 siblings, 1 reply; 5+ messages in thread
From: Zhihang Wei @ 2025-11-04 12:25 UTC (permalink / raw)
To: Felix Moessbauer, isar-users
Cc: jan.kiszka, cedric.hombourger, Benedikt Niedermayr
Hi,
The patch caused one test failed on fast CI, and another failed on full CI.
For fast CI, the failed test case is citest.py:CrossTest.test_cross, when
building target 'mc:phyboard-mira-bookworm:isar-image-base'. Log follows:
21:11:12 (07/22)
/build/isar_wzh_3_fast/21/testsuite/citest.py:CrossTest.test_cross: STARTED
21:52:04 (07/22)
/build/isar_wzh_3_fast/21/testsuite/citest.py:CrossTest.test_cross:
FAIL: Bitbake failed (2451.57 s)
[stdlog] 2025-11-03 21:45:44,063 avocado.app cibuilder L0322 ERROR|
ERROR: mc:phyboard-mira-bookworm:example-module-phy-1.0-r0
do_dpkg_build:
ExecutionError('/build/isar_wzh_3_fast/21/build/tmp/work/debian-bookworm-armhf/example-module-phy/1.0-r0/temp/run.dpkg_runbuild.2797715',
3, None, None)
[stdlog] 2025-11-03 21:45:44,063 avocado.test cibuilder L0320 INFO | Log
data follows:
[stdlog] 2025-11-03 21:45:44,063 avocado.app cibuilder L0322 ERROR|
ERROR: Logfile of failure stored in:
/build/isar_wzh_3_fast/21/build/tmp/work/debian-bookworm-armhf/example-module-phy/1.0-r0/temp/log.do_dpkg_build.2797715
DEBUG: Executing python function sstate_task_prefunc
DEBUG: Python function sstate_task_prefunc finished
DEBUG: Executing python function do_dpkg_build
DEBUG: Executing shell function dpkg_schroot_create_configs
Creating
/etc/schroot/chroot.d/isar-jenkins-c83a1f30-2c3c-4e94-9101-7bae88f0c388-2797715
DEBUG: Shell function dpkg_schroot_create_configs finished
DEBUG: Executing shell function dpkg_runbuild
sbuild (Debian sbuild) 0.85.0 (04 January 2023) on arqalyq.m.ilbers.de
+==============================================================================+
| example-module-phy 1.0 (armhf) Mon, 03 Nov 2025 20:43:20
+0000 |
+==============================================================================+
Package: example-module-phy
Version: 1.0
Source Version: 1.0
Distribution: isar
Machine Architecture: amd64
Host Architecture: armhf
Build Architecture: amd64
Build Profiles: cross
Build Type: binary
I: NOTICE: Log filtering will replace
'var/run/schroot/mount/isar-jenkins-c83a1f30-2c3c-4e94-9101-7bae88f0c388-2797715-d5717322-f8d3-4405-8cca-3c6de6d5cb2e'
with '<<CHROOT>>'
+------------------------------------------------------------------------------+
| Chroot Setup Commands |
+------------------------------------------------------------------------------+
echo "Package: *\nPin: release n=isar\nPin-Priority: 1000" >
/etc/apt/preferences.d/isar-apt
--------------------------------------------------------------------------------------------
I: Finished running 'echo "Package: *\nPin: release
n=isar\nPin-Priority: 1000" > /etc/apt/preferences.d/isar-apt'.
echo "APT::Get::allow-downgrades 1;" > /etc/apt/apt.conf.d/50isar-apt
---------------------------------------------------------------------
I: Finished running 'echo "APT::Get::allow-downgrades 1;" >
/etc/apt/apt.conf.d/50isar-apt'.
rm -f /var/log/dpkg.log
-----------------------
I: Finished running 'rm -f /var/log/dpkg.log'.
mkdir -p /var/cache/apt/archives
--------------------------------
I: Finished running 'mkdir -p /var/cache/apt/archives'.
find /home/builder/example-module-phy/rootfs/var/cache/apt/archives
-maxdepth 1 -name '*.deb' -exec ln -t /var/cache/apt/archives/ -sf {} +
-------------------------------------------------------------------------------------------------------------------------------------------
I: Finished running 'find
/home/builder/example-module-phy/rootfs/var/cache/apt/archives -maxdepth
1 -name '*.deb' -exec ln -t /var/cache/apt/archives/ -sf {} +'.
apt-get update -o Dir::Etc::SourceList="sources.list.d/isar-apt.list" -o
Dir::Etc::SourceParts="-" -o APT::Get::List-Cleanup="0"
--------------------------------------------------------------------------------------------------------------------------------
Get:1 file:/isar-apt isar InRelease
Ign:1 file:/isar-apt isar InRelease
Get:2 file:/isar-apt isar Release [5105 B]
Get:2 file:/isar-apt isar Release [5105 B]
Get:3 file:/isar-apt isar Release.gpg
Ign:3 file:/isar-apt isar Release.gpg
Get:4 file:/isar-apt isar/main Sources [5394 B]
Get:5 file:/isar-apt isar/main amd64 Packages [2762 B]
Get:6 file:/isar-apt isar/main armhf Packages [5352 B]
Reading package lists...
I: Finished running 'apt-get update -o
Dir::Etc::SourceList="sources.list.d/isar-apt.list" -o
Dir::Etc::SourceParts="-" -o APT::Get::List-Cleanup="0"'.
Finished processing commands.
--------------------------------------------------------------------------------
I: NOTICE: Log filtering will replace
'build/example-module-phy-32rpQ2/resolver-lDWJSX' with '<<RESOLVERDIR>>'
+------------------------------------------------------------------------------+
| Update chroot |
+------------------------------------------------------------------------------+
Reading package lists...
Building dependency tree...
Reading state information...
Calculating upgrade...
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
+------------------------------------------------------------------------------+
| Fetch source files |
+------------------------------------------------------------------------------+
Local sources
-------------
/build/isar_wzh_3_fast/21/build/tmp/work/debian-bookworm-armhf/example-module-phy/1.0-r0/example-module-phy_1.0.dsc
exists in
/build/isar_wzh_3_fast/21/build/tmp/work/debian-bookworm-armhf/example-module-phy/1.0-r0;
copying to chroot
I: NOTICE: Log filtering will replace
'build/example-module-phy-32rpQ2/example-module-phy-1.0' with
'<<PKGBUILDDIR>>'
I: NOTICE: Log filtering will replace 'build/example-module-phy-32rpQ2'
with '<<BUILDDIR>>'
+------------------------------------------------------------------------------+
| Install package build dependencies |
+------------------------------------------------------------------------------+
Setup apt archive
-----------------
Merged Build-Depends: debhelper-compat (= 13), linux-headers-phy,
build-essential:amd64, fakeroot:amd64, crossbuild-essential-armhf:amd64,
libc-dev:armhf, libstdc++-dev:armhf
Filtered Build-Depends: debhelper-compat (= 13), linux-headers-phy,
build-essential:amd64, fakeroot:amd64, crossbuild-essential-armhf:amd64,
libc-dev:armhf, libstdc++-dev:armhf
dpkg-deb: building package 'sbuild-build-depends-main-dummy' in
'/<<RESOLVERDIR>>/apt_archive/sbuild-build-depends-main-dummy.deb'.
Ign:1 copy:/<<RESOLVERDIR>>/apt_archive ./ InRelease
Get:2 copy:/<<RESOLVERDIR>>/apt_archive ./ Release [609 B]
Ign:3 copy:/<<RESOLVERDIR>>/apt_archive ./ Release.gpg
Get:4 copy:/<<RESOLVERDIR>>/apt_archive ./ Sources [708 B]
Get:5 copy:/<<RESOLVERDIR>>/apt_archive ./ Packages [751 B]
Fetched 2068 B in 0s (50.9 kB/s)
Reading package lists...
Reading package lists...
Install main build dependencies (apt-based resolver)
----------------------------------------------------
Installing build dependencies
Reading package lists...
Building dependency tree...
Reading state information...
The solver encountered an error of type: ERR_UNSOLVABLE
The following information might help you to understand what is wrong:
The following packages have unmet dependencies:
linux-headers-phy:armhf : Depends: linux-kbuild-phy:armhf but it is
not installable or
linux-kbuild-phy-armhf-cross:armhf but it is not installable
Execute external solver...
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
sbuild-build-depends-main-dummy:armhf : Depends:
linux-headers-phy:armhf but it is not going to be installed
E: External solver failed with: The following packages have unmet
dependencies:
apt-get failed.
E: Package installation failed
Not removing build depends: cloned chroot in use
Reading package lists...
Building dependency tree...
Reading state information...
The solver encountered an error of type: ERR_UNSOLVABLE
The following information might help you to understand what is wrong:
The following packages have unmet dependencies:
linux-headers-phy:armhf : Depends: linux-kbuild-phy:armhf but it is
not installable or
linux-kbuild-phy-armhf-cross:armhf but it is not installable
Execute external solver...
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
sbuild-build-depends-main-dummy:armhf : Depends:
linux-headers-phy:armhf but it is not going to be installed
E: External solver failed with: The following packages have unmet
dependencies:
apt-get failed.
For full CI, the failed test case is citest.py:KernelTests.test_per_kernel.
Log follows:
20:17:33 (07/48)
/build/isar_wzh_devel_2/8/testsuite/citest.py:KernelTests.test_per_kernel:
STARTED
20:26:41 (07/48)
/build/isar_wzh_devel_2/8/testsuite/citest.py:KernelTests.test_per_kernel:
FAIL: Bitbake failed (547.80 s)
[stdlog] 2025-11-03 20:25:41,022 avocado.app cibuilder L0322 ERROR|
ERROR: mc:qemuarm64-bookworm:example-module-mainline-1.0-r0
do_dpkg_build:
ExecutionError('/build/isar_wzh_devel_2/8/build/tmp/work/debian-bookworm-arm64/example-module-mainline/1.0-r0/temp/run.dpkg_runbuild.3369904',
3, None, None)
[stdlog] 2025-11-03 20:25:41,022 avocado.test cibuilder L0320 INFO | Log
data follows:
[stdlog] 2025-11-03 20:25:41,022 avocado.app cibuilder L0322 ERROR|
ERROR: Logfile of failure stored in:
/build/isar_wzh_devel_2/8/build/tmp/work/debian-bookworm-arm64/example-module-mainline/1.0-r0/temp/log.do_dpkg_build.3369904
[stdlog] 2025-11-03 20:25:41,022 avocado.test cibuilder L0320 INFO | |
DEBUG: Executing python function sstate_task_prefunc
[stdlog] 2025-11-03 20:25:41,023 avocado.app cibuilder L0322 ERROR|
ERROR: Task
(mc:qemuarm64-bookworm:virtual:per-kernel:mainline:/build/isar_wzh_devel_2/8/meta-isar/recipes-kernel/example-module/example-module.bb:do_dpkg_build)
failed with exit code '1'
DEBUG: Executing python function sstate_task_prefunc
DEBUG: Python function sstate_task_prefunc finished
DEBUG: Executing python function do_dpkg_build
DEBUG: Executing shell function dpkg_schroot_create_configs
Creating
/etc/schroot/chroot.d/isar-builder-14a278ef-6154-47ed-818a-ce779ad05af2-476170
DEBUG: Shell function dpkg_schroot_create_configs finished
DEBUG: Executing shell function dpkg_runbuild
sbuild (Debian sbuild) 0.85.0 (04 January 2023) on ecf5e4d8eab2
+==============================================================================+
| example-module-mainline 1.0 (arm64) Tue, 04 Nov 2025 09:09:25
+0000 |
+==============================================================================+
Package: example-module-mainline
Version: 1.0
Source Version: 1.0
Distribution: isar
Machine Architecture: amd64
Host Architecture: arm64
Build Architecture: amd64
Build Profiles: cross
Build Type: binary
I: NOTICE: Log filtering will replace
'var/run/schroot/mount/isar-builder-14a278ef-6154-47ed-818a-ce779ad05af2-476170-f0be66c4-3503-406e-a046-128e9596ef80'
with '<<CHROOT>>'
+------------------------------------------------------------------------------+
| Chroot Setup Commands |
+------------------------------------------------------------------------------+
echo "Package: *\nPin: release n=isar\nPin-Priority: 1000" >
/etc/apt/preferences.d/isar-apt
--------------------------------------------------------------------------------------------
I: Finished running 'echo "Package: *\nPin: release
n=isar\nPin-Priority: 1000" > /etc/apt/preferences.d/isar-apt'.
echo "APT::Get::allow-downgrades 1;" > /etc/apt/apt.conf.d/50isar-apt
---------------------------------------------------------------------
I: Finished running 'echo "APT::Get::allow-downgrades 1;" >
/etc/apt/apt.conf.d/50isar-apt'.
rm -f /var/log/dpkg.log
-----------------------
I: Finished running 'rm -f /var/log/dpkg.log'.
mkdir -p /var/cache/apt/archives
--------------------------------
I: Finished running 'mkdir -p /var/cache/apt/archives'.
find /home/builder/example-module-mainline/rootfs/var/cache/apt/archives
-maxdepth 1 -name '*.deb' -exec ln -t /var/cache/apt/archives/ -sf {} +
------------------------------------------------------------------------------------------------------------------------------------------------
I: Finished running 'find
/home/builder/example-module-mainline/rootfs/var/cache/apt/archives
-maxdepth 1 -name '*.deb' -exec ln -t /var/cache/apt/archives/ -sf {} +'.
apt-get update -o Dir::Etc::SourceList="sources.list.d/isar-apt.list" -o
Dir::Etc::SourceParts="-" -o APT::Get::List-Cleanup="0"
--------------------------------------------------------------------------------------------------------------------------------
Get:1 file:/isar-apt isar InRelease
Ign:1 file:/isar-apt isar InRelease
Get:2 file:/isar-apt isar Release [5087 B]
Get:2 file:/isar-apt isar Release [5087 B]
Get:3 file:/isar-apt isar Release.gpg
Ign:3 file:/isar-apt isar Release.gpg
Get:4 file:/isar-apt isar/main Sources [2834 B]
Get:5 file:/isar-apt isar/main armhf Packages [1532 B]
Get:6 file:/isar-apt isar/main arm64 Packages [2695 B]
Get:7 file:/isar-apt isar/main amd64 Packages [893 B]
Reading package lists...
I: Finished running 'apt-get update -o
Dir::Etc::SourceList="sources.list.d/isar-apt.list" -o
Dir::Etc::SourceParts="-" -o APT::Get::List-Cleanup="0"'.
Finished processing commands.
--------------------------------------------------------------------------------
I: NOTICE: Log filtering will replace
'build/example-module-mainline-Om9YZL/resolver-cMiwQg' with
'<<RESOLVERDIR>>'
+------------------------------------------------------------------------------+
| Update chroot |
+------------------------------------------------------------------------------+
Reading package lists...
Building dependency tree...
Reading state information...
Calculating upgrade...
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
+------------------------------------------------------------------------------+
| Fetch source files |
+------------------------------------------------------------------------------+
Local sources
-------------
/work/build/tmp/work/debian-bookworm-arm64/example-module-mainline/1.0-r0/example-module-mainline_1.0.dsc
exists in
/work/build/tmp/work/debian-bookworm-arm64/example-module-mainline/1.0-r0;
copying to chroot
I: NOTICE: Log filtering will replace
'build/example-module-mainline-Om9YZL/example-module-mainline-1.0' with
'<<PKGBUILDDIR>>'
I: NOTICE: Log filtering will replace
'build/example-module-mainline-Om9YZL' with '<<BUILDDIR>>'
+------------------------------------------------------------------------------+
| Install package build dependencies |
+------------------------------------------------------------------------------+
Setup apt archive
-----------------
Merged Build-Depends: debhelper-compat (= 13), linux-headers-mainline,
build-essential:amd64, fakeroot:amd64, crossbuild-essential-arm64:amd64,
libc-dev:arm64, libstdc++-dev:arm64
Filtered Build-Depends: debhelper-compat (= 13), linux-headers-mainline,
build-essential:amd64, fakeroot:amd64, crossbuild-essential-arm64:amd64,
libc-dev:arm64, libstdc++-dev:arm64
dpkg-deb: building package 'sbuild-build-depends-main-dummy' in
'/<<RESOLVERDIR>>/apt_archive/sbuild-build-depends-main-dummy.deb'.
Ign:1 copy:/<<RESOLVERDIR>>/apt_archive ./ InRelease
Get:2 copy:/<<RESOLVERDIR>>/apt_archive ./ Release [609 B]
Ign:3 copy:/<<RESOLVERDIR>>/apt_archive ./ Release.gpg
Get:4 copy:/<<RESOLVERDIR>>/apt_archive ./ Sources [713 B]
Get:5 copy:/<<RESOLVERDIR>>/apt_archive ./ Packages [756 B]
Fetched 2078 B in 0s (0 B/s)
Reading package lists...
Reading package lists...
Install main build dependencies (apt-based resolver)
----------------------------------------------------
Installing build dependencies
Reading package lists...
Building dependency tree...
Reading state information...
The solver encountered an error of type: ERR_UNSOLVABLE
The following information might help you to understand what is wrong:
The following packages have unmet dependencies:
linux-headers-mainline:arm64 : Depends: linux-kbuild-mainline:arm64
but it is not installable or
linux-kbuild-mainline-arm64-cross:arm64 but it is not installable
Execute external solver...
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
sbuild-build-depends-main-dummy:arm64 : Depends:
linux-headers-mainline:arm64 but it is not going to be installed
E: External solver failed with: The following packages have unmet
dependencies:
apt-get failed.
E: Package installation failed
Not removing build depends: cloned chroot in use
Reading package lists...
Building dependency tree...
Reading state information...
The solver encountered an error of type: ERR_UNSOLVABLE
The following information might help you to understand what is wrong:
The following packages have unmet dependencies:
linux-headers-mainline:arm64 : Depends: linux-kbuild-mainline:arm64
but it is not installable or
linux-kbuild-mainline-arm64-cross:arm64 but it is not installable
Execute external solver...
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
sbuild-build-depends-main-dummy:arm64 : Depends:
linux-headers-mainline:arm64 but it is not going to be installed
E: External solver failed with: The following packages have unmet
dependencies:
apt-get failed.
You can redo the test on your machine using avocado:
1. Have a clean clone of isar, checkout to branch next and apply your
patches:
$ git clone -b next https://github.com/ilbers/isar.git
$ cd isar
$ git am /path-to/0001-my-contribution-to-isar.patch
2. Disable several unrelated targets to make error appears faster, by
applying
the following diff:
diff --git a/testsuite/citest.py b/testsuite/citest.py
index 675015af..f573a9a7 100755
--- a/testsuite/citest.py
+++ b/testsuite/citest.py
@@ -197,13 +197,6 @@ class CrossTest(CIBaseTest):
def test_cross(self):
targets = [
- 'mc:qemuarm-buster:isar-image-ci',
- 'mc:qemuarm-bullseye:isar-image-ci',
- 'mc:de0-nano-soc-bullseye:isar-image-base',
- 'mc:stm32mp15x-bullseye:isar-image-base',
- 'mc:qemuarm-bookworm:isar-image-ci',
- 'mc:qemuarm64-focal:isar-image-base',
- 'mc:nanopi-neo-efi-bookworm:isar-image-base',
'mc:phyboard-mira-bookworm:isar-image-base',
]
3.Run kas shell, setup CI prerequisites (avocado, qemu) and cleanup:
$ ./kas/kas-container shell kas/isar.yaml --command \
"rm -rf /work/build/conf && /work/scripts/ci_setup.sh"
4.Run the failed test in fast:
$ cd /work/testsuite
$ avocado run citest.py:CrossTest.test_cross$
4.Run the failed test in full:
$ avocado run citest.py:KernelTests.test_per_kernel
Best regards,
Zhihang
On 11/3/25 17:01, 'Felix Moessbauer' via isar-users wrote:
> When building a -native package, the cross profile must not be added as
> otherwise stricter apt cache checks added in trixie trigger. It anyways
> makes no sense to add the cross profile when BUILD_ARCH equals
> PACKAGE_ARCH. Previously this check was implemented incorrectly, as the
> build arch was compared to the DISTRO_ARCH, which is always the target
> arch in isar terms. This resulted in the following error message in
> sbuild:
>
> E: The package cache was built for different architectures: amd64 vs arm64
> W: You may want to run apt-get update to correct these problems
> E: The package cache file is corrupted
> E: apt-get dist-upgrade failed
>
> On bookworm, the incorrect check remained unnoticed, as apt did not have
> the stricter checks yet.
>
> Fixes: 872ef2e3 ("dpkg-base: Fix enabling of cross build profile")
> Tested-by: Benedikt Niedermayr <benedikt.niedermayr@siemens.com>
> Signed-off-by: Felix Moessbauer <felix.moessbauer@siemens.com>
> ---
> meta/classes/dpkg-base.bbclass | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/meta/classes/dpkg-base.bbclass b/meta/classes/dpkg-base.bbclass
> index 4468a49a..d8287e8d 100644
> --- a/meta/classes/dpkg-base.bbclass
> +++ b/meta/classes/dpkg-base.bbclass
> @@ -146,7 +146,7 @@ dpkg_runbuild() {
>
> def isar_deb_build_profiles(d):
> deb_build_profiles = d.getVar('DEB_BUILD_PROFILES')
> - if d.getVar('BUILD_ARCH') != d.getVar('DISTRO_ARCH'):
> + if d.getVar('BUILD_ARCH') != d.getVar('PACKAGE_ARCH'):
> deb_build_profiles += ' cross'
> return deb_build_profiles.strip()
>
--
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/414bb670-e392-49a9-828f-f0528b765e30%40ilbers.de.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH 1/2] do not add cross profile when building native package
2025-11-04 12:25 ` Zhihang Wei
@ 2025-11-04 14:20 ` 'MOESSBAUER, Felix' via isar-users
0 siblings, 0 replies; 5+ messages in thread
From: 'MOESSBAUER, Felix' via isar-users @ 2025-11-04 14:20 UTC (permalink / raw)
To: isar-users, wzh; +Cc: Niedermayr, BENEDIKT, Kiszka, Jan, cedric.hombourger
On Tue, 2025-11-04 at 13:25 +0100, Zhihang Wei wrote:
> Hi,
>
> The patch caused one test failed on fast CI, and another failed on full CI.
>
> For fast CI, the failed test case is citest.py:CrossTest.test_cross, when
> building target 'mc:phyboard-mira-bookworm:isar-image-base'. Log follows:
Hi, thanks for this report. Unfortunately I'm still not able to execute
the whole testsuite due to the issues reported in the other thread.
With the reproducer from below I was able to pin-point the issue.
Actually, it fails because the cross-profile variant of the kernel
build does not set the cross profile. This just worked previously, as
the cross profile was accidentally added for that special case as well
- which is no longer true.
The following patch fixes this for me. I'll add it to the series and
send a v2. Hopefully this will then pass the CI.
diff --git a/meta/recipes-kernel/linux/linux-custom.inc b/meta/recipes-
kernel/linux/linux-custom.inc
index f2892921..c3fe4fc1 100644
--- a/meta/recipes-kernel/linux/linux-custom.inc
+++ b/meta/recipes-kernel/linux/linux-custom.inc
@@ -221,6 +221,7 @@ def get_additional_build_profiles(d):
KERNEL_LIBC_DEV_ARCH = "${@ bb.utils.contains('DEB_BUILD_PROFILES',
'libcdev-arch-all', 'all\nMulti-Arch: foreign', 'any', d) }"
DEB_BUILD_PROFILES += "${@get_additional_build_profiles(d)}"
+DEB_BUILD_PROFILES:append:cross-profile = " cross"
Best regards,
Felix
>
> 21:11:12 (07/22)
> /build/isar_wzh_3_fast/21/testsuite/citest.py:CrossTest.test_cross: STARTED
> 21:52:04 (07/22)
> /build/isar_wzh_3_fast/21/testsuite/citest.py:CrossTest.test_cross:
> FAIL: Bitbake failed (2451.57 s)
>
> [stdlog] 2025-11-03 21:45:44,063 avocado.app cibuilder L0322 ERROR|
> ERROR: mc:phyboard-mira-bookworm:example-module-phy-1.0-r0
> do_dpkg_build:
> ExecutionError('/build/isar_wzh_3_fast/21/build/tmp/work/debian-bookworm-armhf/example-module-phy/1.0-r0/temp/run.dpkg_runbuild.2797715',
> 3, None, None)
> [stdlog] 2025-11-03 21:45:44,063 avocado.test cibuilder L0320 INFO | Log
> data follows:
> [stdlog] 2025-11-03 21:45:44,063 avocado.app cibuilder L0322 ERROR|
> ERROR: Logfile of failure stored in:
> /build/isar_wzh_3_fast/21/build/tmp/work/debian-bookworm-armhf/example-module-phy/1.0-r0/temp/log.do_dpkg_build.2797715
>
> DEBUG: Executing python function sstate_task_prefunc
> DEBUG: Python function sstate_task_prefunc finished
> DEBUG: Executing python function do_dpkg_build
> DEBUG: Executing shell function dpkg_schroot_create_configs
> Creating
> /etc/schroot/chroot.d/isar-jenkins-c83a1f30-2c3c-4e94-9101-7bae88f0c388-2797715
> DEBUG: Shell function dpkg_schroot_create_configs finished
> DEBUG: Executing shell function dpkg_runbuild
> sbuild (Debian sbuild) 0.85.0 (04 January 2023) on arqalyq.m.ilbers.de
>
>
--
Siemens AG
Linux Expert Center
Friedrich-Ludwig-Bauer-Str. 3
85748 Garching, Germany
--
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/13b33434835634a6aa803db8b99c06efdbf2717e.camel%40siemens.com.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2025-11-04 14:20 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-11-03 16:01 [PATCH 1/2] do not add cross profile when building native package 'Felix Moessbauer' via isar-users
2025-11-03 16:01 ` [PATCH 2/2] propagate distro-specific dependencies of arch all packages 'Felix Moessbauer' via isar-users
2025-11-03 16:05 ` [PATCH 1/2] do not add cross profile when building native package 'Jan Kiszka' via isar-users
2025-11-04 12:25 ` Zhihang Wei
2025-11-04 14:20 ` 'MOESSBAUER, Felix' via isar-users
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox