public inbox for isar-users@googlegroups.com
 help / color / mirror / Atom feed
From: "'Felix Moessbauer' via isar-users" <isar-users@googlegroups.com>
To: isar-users@googlegroups.com
Cc: stefan-koch@siemens.com, jan.kiszka@siemens.com,
	anaumann@emlix.com,
	Felix Moessbauer <felix.moessbauer@siemens.com>,
	Benedikt Niedermayr <benedikt.niedermayr@siemens.com>
Subject: [PATCH v3 4/4] propagate distro-specific dependencies of arch all packages
Date: Thu,  6 Nov 2025 15:11:22 +0100	[thread overview]
Message-ID: <20251106141122.2887558-5-felix.moessbauer@siemens.com> (raw)
In-Reply-To: <20251106141122.2887558-1-felix.moessbauer@siemens.com>

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.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/20251106141122.2887558-5-felix.moessbauer%40siemens.com.

  parent reply	other threads:[~2025-11-06 14:11 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-11-06 14:11 [PATCH v3 0/4] " 'Felix Moessbauer' via isar-users
2025-11-06 14:11 ` [PATCH v3 1/4] linux-custom: prefix profile names according to BuildProfileSpec 'Felix Moessbauer' via isar-users
2025-11-06 16:55   ` 'Jan Kiszka' via isar-users
2025-11-07  8:19     ` 'MOESSBAUER, Felix' via isar-users
2025-11-06 14:11 ` [PATCH v3 2/4] linux-custom: fix name collision on cross profile 'Felix Moessbauer' via isar-users
2025-11-06 14:11 ` [PATCH v3 3/4] do not add cross profile when building native package 'Felix Moessbauer' via isar-users
2025-11-06 14:11 ` 'Felix Moessbauer' via isar-users [this message]
2025-11-07 10:09 ` [PATCH v3 0/4] propagate distro-specific dependencies of arch all packages Zhihang Wei
2025-11-07 10:20   ` 'MOESSBAUER, Felix' via isar-users

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=20251106141122.2887558-5-felix.moessbauer@siemens.com \
    --to=isar-users@googlegroups.com \
    --cc=anaumann@emlix.com \
    --cc=benedikt.niedermayr@siemens.com \
    --cc=felix.moessbauer@siemens.com \
    --cc=jan.kiszka@siemens.com \
    --cc=stefan-koch@siemens.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