From: Adriaan Schmidt <adriaan.schmidt@siemens.com>
To: <isar-users@googlegroups.com>
Cc: Adriaan Schmidt <adriaan.schmidt@siemens.com>
Subject: [PATCH 2/3] buildchroot: delay expansion of variable BUILDCHROOT_DIR
Date: Tue, 19 Jul 2022 14:39:53 +0200 [thread overview]
Message-ID: <20220719123954.310076-3-adriaan.schmidt@siemens.com> (raw)
In-Reply-To: <20220719123954.310076-1-adriaan.schmidt@siemens.com>
The current implementation expands ${BUILDCHROOT_DIR_HOST|TARGET} during
assignment to BUILDCHROOT_DIR, which leads to absolute paths in signatures.
This can be observed in IMAGE_CMD_* and CONVERSION_CMD_*, and is bad for caching.
Thus, we delay expansion, and due to the way the do_image_* tasks are created,
the paths in our signatures will be relative to ${TMPDIR} (no expansion).
Signed-off-by: Adriaan Schmidt <adriaan.schmidt@siemens.com>
---
meta/classes/buildchroot.bbclass | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/meta/classes/buildchroot.bbclass b/meta/classes/buildchroot.bbclass
index 11489661..f56c335b 100644
--- a/meta/classes/buildchroot.bbclass
+++ b/meta/classes/buildchroot.bbclass
@@ -12,10 +12,10 @@ python __anonymous() {
if mode == "0" or d.getVar('HOST_ARCH') == distro_arch or \
(d.getVar('HOST_DISTRO') == "debian-stretch" and distro_arch == "i386"):
dep = "buildchroot-target:do_build"
- rootfs = d.getVar('BUILDCHROOT_TARGET_DIR', True)
+ rootfs = d.getVar('BUILDCHROOT_TARGET_DIR', False)
else:
dep = "buildchroot-host:do_build"
- rootfs = d.getVar('BUILDCHROOT_HOST_DIR', True)
+ rootfs = d.getVar('BUILDCHROOT_HOST_DIR', False)
d.setVar('BUILDCHROOT_DEP', dep)
d.setVar('BUILDCHROOT_DIR', rootfs)
--
2.30.2
next prev parent reply other threads:[~2022-07-19 12:40 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-07-19 12:39 [PATCH 0/3] image and buildchroot tweaks Adriaan Schmidt
2022-07-19 12:39 ` [PATCH 1/3] image: set convenience variables in bitbake code Adriaan Schmidt
2022-07-19 12:39 ` Adriaan Schmidt [this message]
2022-07-19 12:39 ` [PATCH 3/3] sstate: remove paths below TMPDIR from BB_HASHBASE_WHITELIST Adriaan Schmidt
2022-07-26 6:53 ` [PATCH 0/3] image and buildchroot tweaks Anton Mikanovich
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=20220719123954.310076-3-adriaan.schmidt@siemens.com \
--to=adriaan.schmidt@siemens.com \
--cc=isar-users@googlegroups.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