From: Uladzimir Bely <ubely@ilbers.de>
To: isar-users@googlegroups.com
Subject: [PATCH v5 00/12] Sbuild/Schroot migration
Date: Tue, 1 Feb 2022 18:00:26 +0100 [thread overview]
Message-ID: <20220201170038.5723-1-ubely@ilbers.de> (raw)
This is a patchset showing how sbuild/schroot tools can be integrated
into Isar build system.
This patchset should be applied on top of "preparation" patchset
named "Avoid using shell environment during the build".
Base schroot image is created with sbuild-chroot-target (or
sbuild-chroot-host in case of cross-build) recipe. These images are based
on isar-bootstrap ones, but include some build-related stuff preinstalled.
To use this changes you need to have sbuild and schroot installed and
configured. Current user should be added to sbuild group.
If 'kas-container' is used, it should be modified to support sbuild:
- /var/lib/schroot/union/overlay should be externally mounted (-v option)
Currently, sbuild-related stuff is supported in kas-isar:next image
To use the patchset with KAS:
- export KAS_IMAGE_VERSION=next
If 'gitlab' is used, the similar changes are required:
- `next` tag for kas image should be set
- external dir for schroot overlay should also be specified in
/etc/gitlab-runner/config.toml:
volumes = ["/path/to/overlay:/var/lib/schroot/union/overlay"]
The patchset was tested with 'meta-iot2050' and 'xenomai-images'
downstreams in combination with kas image mentioned above.
Current limitations:
- parallel building of several packages requires more free space in
comparison with buildchroot-based architecture. This happens due
the sbuild architecture which uses some basic layer (common for all
packages) and per-package separate layer (where builddeps are downloaded
and installed).
Changes since v4:
- consider shell exports done in dpkg_runbuild_prepend and pass them
to sbuild environment;
- fixed ccache work.
Changes since v3:
- dpkg_do_mounts() and dpkg_undo_mounts() are not removed for downstreams
compatibility;
- dpkg_build_export is used for adjusting sbuild environment;
- DEB_BUILD_PROFILES support for sbuild is fixed in case of cross-build.
Changes since v2:
- patches reworked/squashed for easier reading and understanding;
- fixed building foreigh architectures with kas-docker;
- implemented support of ccache;
- fixed devshell and devshell_nodeps,
Changes since v1:
- parallel builds with different BUILD_DIR are supported;
- parallel multiconfig targets in one build are supported;
- per-task schroot configuration in /etc/schroot/ is now used;
- patchset now passes Jenkins CI (so patches changes RFC => PATCH).
Anton Mikanovich (1):
dpkg: Build packages with sbuild
Uladzimir Bely (11):
dpkg-gbp: Use separate command to export tarball
dpkg-gbp: Use host tools for dsc preparation
sbuild: Add recipes for host and target rootfs to run sbuild
sbuild: Introduce a class for another build method
sbuild: support of DEB_BUILD_PROFILES
sbuild: support of shell exports from dpkg_runbuild_prepend
dpkg: Remove builddeps install task.
sbuild: add ccache support
dpkg-base: Switch devshell to use schroot
dpkg-base: Switch apt_fetch and apt_unpack to use schroot
doc: Add sbuild-related documentation
doc/user_manual.md | 22 ++-
meta/classes/dpkg-base.bbclass | 79 ++++----
meta/classes/dpkg-gbp.bbclass | 26 +--
meta/classes/dpkg.bbclass | 80 +++++---
meta/classes/sbuild.bbclass | 184 ++++++++++++++++++
meta/conf/bitbake.conf | 2 +
.../sbuild-chroot/sbuild-chroot-host.bb | 13 ++
.../sbuild-chroot/sbuild-chroot-target.bb | 10 +
.../sbuild-chroot/sbuild-chroot.inc | 39 ++++
9 files changed, 375 insertions(+), 80 deletions(-)
create mode 100644 meta/classes/sbuild.bbclass
create mode 100644 meta/recipes-devtools/sbuild-chroot/sbuild-chroot-host.bb
create mode 100644 meta/recipes-devtools/sbuild-chroot/sbuild-chroot-target.bb
create mode 100644 meta/recipes-devtools/sbuild-chroot/sbuild-chroot.inc
--
2.20.1
next reply other threads:[~2022-02-01 17:00 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-02-01 17:00 Uladzimir Bely [this message]
2022-02-01 17:00 ` [PATCH v5 01/12] dpkg-gbp: Use separate command to export tarball Uladzimir Bely
2022-02-01 17:00 ` [PATCH v5 02/12] dpkg-gbp: Use host tools for dsc preparation Uladzimir Bely
2022-02-01 17:00 ` [PATCH v5 03/12] sbuild: Add recipes for host and target rootfs to run sbuild Uladzimir Bely
2022-02-01 17:00 ` [PATCH v5 04/12] sbuild: Introduce a class for another build method Uladzimir Bely
2022-02-01 17:00 ` [PATCH v5 05/12] dpkg: Build packages with sbuild Uladzimir Bely
2022-02-01 17:00 ` [PATCH v5 06/12] sbuild: support of DEB_BUILD_PROFILES Uladzimir Bely
2022-02-01 17:00 ` [PATCH v5 07/12] sbuild: support of shell exports from dpkg_runbuild_prepend Uladzimir Bely
2022-02-01 18:09 ` Jan Kiszka
2022-02-01 18:41 ` Uladzimir Bely
2022-02-02 6:57 ` Jan Kiszka
2022-02-02 8:46 ` Moessbauer, Felix
2022-02-02 8:52 ` Jan Kiszka
2022-02-02 9:13 ` Uladzimir Bely
2022-02-02 9:46 ` Jan Kiszka
2022-02-01 17:00 ` [PATCH v5 08/12] dpkg: Remove builddeps install task Uladzimir Bely
2022-02-01 17:00 ` [PATCH v5 09/12] sbuild: add ccache support Uladzimir Bely
2022-02-01 17:00 ` [PATCH v5 10/12] dpkg-base: Switch devshell to use schroot Uladzimir Bely
2022-02-01 17:00 ` [PATCH v5 11/12] dpkg-base: Switch apt_fetch and apt_unpack " Uladzimir Bely
2022-02-01 17:00 ` [PATCH v5 12/12] doc: Add sbuild-related documentation Uladzimir Bely
2022-02-01 18:14 ` [PATCH v5 00/12] Sbuild/Schroot migration Jan Kiszka
2022-02-01 18:33 ` Uladzimir Bely
2022-02-02 7:01 ` 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=20220201170038.5723-1-ubely@ilbers.de \
--to=ubely@ilbers.de \
--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