From: Jan Kiszka <jan.kiszka@siemens.com>
To: isar-users <isar-users@googlegroups.com>,
Alexander Smirnov <asmirnov@ilbers.de>,
Maksim Osipov <mosipov@ilbers.de>
Subject: crossbuild broken with host-distro != target-distro
Date: Mon, 27 Aug 2018 21:51:45 +0200 [thread overview]
Message-ID: <7074054d-bb57-dc87-5bb4-f74eca265c51@siemens.com> (raw)
Hi folks,
I ran into a remaining glitch for the crossbuild support: When the
target distro name differs from the host distro, buildchroot-host fails.
That initially looked like it would be easy to fix and even made sense
for a while:
diff --git a/meta/recipes-devtools/buildchroot/buildchroot-host.bb b/meta/recipes-devtools/buildchroot/buildchroot-host.bb
index daf92a2..01d426d 100644
--- a/meta/recipes-devtools/buildchroot/buildchroot-host.bb
+++ b/meta/recipes-devtools/buildchroot/buildchroot-host.bb
@@ -30,5 +30,5 @@ BUILDCHROOT_PREINSTALL_append_arm64 += "binutils-aarch64-linux-gnu \
crossbuild-essential-arm64"
-PARAMS = "--host-arch"
+PARAMS = "--host-arch --host-distro"
do_build[depends] = "isar-apt:do_cache_config isar-bootstrap-host:do_bootstrap"
However, that only broke setup_root_file_system differently because it
now tried to mount the non-existing host isar-apt repo. Workaround hack:
diff --git a/meta/classes/isar-bootstrap-helper.bbclass b/meta/classes/isar-bootstrap-helper.bbclass
index d45cdd7..4ad552f 100644
--- a/meta/classes/isar-bootstrap-helper.bbclass
+++ b/meta/classes/isar-bootstrap-helper.bbclass
@@ -93,9 +93,9 @@ setup_root_file_system() {
sudo tee "$ROOTFSDIR/etc/apt/preferences.d/isar" >/dev/null
if [ ${COPYISARAPT} ]; then
- sudo cp -Trpfx ${DEPLOY_DIR_APT}/${ROOTFS_DISTRO} $ROOTFSDIR/isar-apt
+ sudo cp -Trpfx ${DEPLOY_DIR_APT}/${DISTRO} $ROOTFSDIR/isar-apt
else
- sudo mount --bind ${DEPLOY_DIR_APT}/${ROOTFS_DISTRO} $ROOTFSDIR/isar-apt
+ sudo mount --bind ${DEPLOY_DIR_APT}/${DISTRO} $ROOTFSDIR/isar-apt
fi
sudo mount -t devtmpfs -o mode=0755,nosuid devtmpfs $ROOTFSDIR/dev
sudo mount -t proc none $ROOTFSDIR/proc
That will likely break sdkchroot, the only recipe that depends on
isar-apt-host, so far the only caller of setup_root_file_system that
passed --host-distro. But I'm not getting yet why the SDK has some own
isar-apt repo and no one else. Can you clarify and maybe even explain
how to fix the issue best?
Thanks,
Jan
--
Siemens AG, Corporate Technology, CT RDA IOT SES-DE
Corporate Competence Center Embedded Linux
next reply other threads:[~2018-08-27 19:51 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-08-27 19:51 Jan Kiszka [this message]
2018-08-30 9:24 ` Jan Kiszka
2018-09-05 8:31 ` Maxim Yu. Osipov
2018-09-05 8:38 ` Jan Kiszka
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=7074054d-bb57-dc87-5bb4-f74eca265c51@siemens.com \
--to=jan.kiszka@siemens.com \
--cc=asmirnov@ilbers.de \
--cc=isar-users@googlegroups.com \
--cc=mosipov@ilbers.de \
/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