From: Jan Kiszka <jan.kiszka@siemens.com>
To: <quirin.gylstorff@siemens.com>, <isar-users@googlegroups.com>,
<ubely@ilbers.de>
Cc: "Schmidl, Tobias (T CED SES-DE)" <tobiasschmidl@siemens.com>
Subject: Re: [PATCH v4 00/12] Sbuild/Schroot migration
Date: Fri, 4 Feb 2022 15:28:51 +0100 [thread overview]
Message-ID: <0ca3459c-56ab-ebf8-37c4-db1f3e1085af@siemens.com> (raw)
In-Reply-To: <db1474f8-fb89-422c-6930-95bf78af2cc8@siemens.com>
On 04.02.22 14:39, quirin.gylstorff@siemens.com wrote:
> Hi,
>
>
> On 1/25/22 13:39, Uladzimir Bely wrote:
>> 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, official `kas` images don't include all required software, so
>> there was an alternative docker image prepared:
>> `docker pull ghcr.io/wiselord/kas/kas-isar:next-sbuild`
>>
>> To use it with KAS:
>> - export KAS_IMAGE_VERSION=3.0.0-sbuild
>> - export KAS_CONTAINER_IMAGE_PATH=ghcr.io/wiselord/kas
>>
>> If 'gitlab' is used, the similar changes are required:
>> - 'image: ghcr.io/wiselord/kas/kas-isar:3.0.0-sbuild' in .gitlab-ci.yml
>> - 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. Some patches are required for these downstreams,
>> appropriate pull requests will be created soon.
>>
>> 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 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: add ccache support
>> dpkg: Remove builddeps install task.
>> dpkg-base: Switch devshell to use schroot
>> dpkg-base: Switch apt_fetch and apt_unpack to use schroot
>> dpkg-base: Cleanup from buildchroot parts.
>> doc: Add sbuild-related documentation
>>
>> doc/user_manual.md | 22 ++-
>> meta/classes/dpkg-base.bbclass | 81 ++++----
>> meta/classes/dpkg-gbp.bbclass | 26 +--
>> meta/classes/dpkg.bbclass | 62 +++---
>> meta/classes/sbuild.bbclass | 185 ++++++++++++++++++
>> 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, 359 insertions(+), 81 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
>>
>
> any thoughts on the clean source behavior[1].
>
> "When running sbuild from within an unpacked source tree, run the
> 'clean' target before generating the source package. This might require
> some of the build dependencies necessary for running the 'clean' target
> to be installed on the host machine. Only disable if you start from a
> clean checkout and you know what you are doing."[1]
> [1]:
> https://manpages.debian.org/unstable/sbuild/sbuild.conf.5.en.html#CLEAN_SOURCE
>
>
> If this is necessary you need to install dh-*(e.g. dh-lua, dh-python) in
> the build environment.
>
Then we would need to expand the host side (builder) dependency list.
And also kas-isar.
Jan
--
Siemens AG, Technology
Competence Center Embedded Linux
prev parent reply other threads:[~2022-02-04 14:28 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-25 12:39 Uladzimir Bely
2022-01-25 12:39 ` [PATCH v4 01/12] dpkg-gbp: Use separate command to export tarball Uladzimir Bely
2022-01-25 12:39 ` [PATCH v4 02/12] dpkg-gbp: Use host tools for dsc preparation Uladzimir Bely
2022-01-25 12:39 ` [PATCH v4 03/12] sbuild: Add recipes for host and target rootfs to run sbuild Uladzimir Bely
2022-01-25 12:39 ` [PATCH v4 04/12] sbuild: Introduce a class for another build method Uladzimir Bely
2022-01-25 12:39 ` [PATCH v4 05/12] dpkg: Build packages with sbuild Uladzimir Bely
2022-01-25 12:39 ` [PATCH v4 06/12] sbuild: support of DEB_BUILD_PROFILES Uladzimir Bely
2022-01-25 12:39 ` [PATCH v4 07/12] sbuild: add ccache support Uladzimir Bely
2022-01-25 12:39 ` [PATCH v4 08/12] dpkg: Remove builddeps install task Uladzimir Bely
2022-01-25 12:39 ` [PATCH v4 09/12] dpkg-base: Switch devshell to use schroot Uladzimir Bely
2022-01-25 12:39 ` [PATCH v4 10/12] dpkg-base: Switch apt_fetch and apt_unpack " Uladzimir Bely
2022-01-25 12:39 ` [PATCH v4 11/12] dpkg-base: Cleanup from buildchroot parts Uladzimir Bely
2022-01-25 12:39 ` [PATCH v4 12/12] doc: Add sbuild-related documentation Uladzimir Bely
2022-02-04 13:39 ` [PATCH v4 00/12] Sbuild/Schroot migration quirin.gylstorff
2022-02-04 14:28 ` Jan Kiszka [this message]
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=0ca3459c-56ab-ebf8-37c4-db1f3e1085af@siemens.com \
--to=jan.kiszka@siemens.com \
--cc=isar-users@googlegroups.com \
--cc=quirin.gylstorff@siemens.com \
--cc=tobiasschmidl@siemens.com \
--cc=ubely@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