Converting to BuildStream, episode III

Sam Thursfield sam.thursfield at codethink.co.uk
Tue Aug 29 13:07:29 BST 2017


Hello,

It's 4 months since Tristan proposed we switch to BuildStream[1]. We
discussed it again in June[2] and Javier suggested the next step was
enabling automated conversions.

I just sent a merge request to add a `convert` script to the
definitions.git repo, and to merge in Tristan's manual .bst conversion
of build-essential:

    https://gitlab.com/baserock/definitions/merge_requests/52

It also modifies .gitlab-ci.yml so that 'master' of definitions is built 
with BuildStream as well as YBD on each commit:

    https://gitlab.com/baserock/definitions/pipelines/11170696

If you want to try out the BuildStream conversion, bear in mind the 
following limitations.

  * Build-essential stuff isn't auto-converted, the
    elements/gnu-toolchain files need to be kept in sync manually

  * Not all existing definitions are converted. See the `convert`
    script for the list of what is converted.[3]

  * Only x86_64 is converted.

  * No deployment instructions are converted.

Here is a list of the work that I think remains along the road of
switching to BuildStream completely.

1. Merge some of the Linux .morph files into a single linux.bst file,
    with the platform-specific kernel config set using arch conditionals
    and target board variants.

    I suggest we drop some of the hardware targets we support as some of
    them are totally obsolete now. The exact set that can be converted
    will probably be decided by who helps out in testing the conversions;
    I can do x86_64, armv8 and PPC64 but I can't promise I'll have time
    to do anything else.

2. Add instructions for producing disk images from the systems;
    we will need to reimplment some of our "write" and "deployment"
    extensions as BuildStream elements.

3. Updating the documentation on wiki.baserock.org.

4. Having a "flag day" where we remove the Baserock definitions, and
    switch formally to BuildStream.

5. Converting infrastructure systems that still use Morph/YBD to
    be built and deployed with BuildStream (or something else
    altogether).

And at this point we can all use BuildStream to build operating systems
from scratch and the world will be a happier place for sure!

Something else that would be interesting and can be done in parallel
is fixing the `unpetrify-ref` / `track` fields we carry, and trying to 
implement automated component updates. The `bst track` command makes it 
fairly simple to do this.

Thanks
Sam


[1]. 
https://listmaster.pepperfish.net/pipermail/baserock-dev-baserock.org/2017-April/013780.html

[2]. Episode II: 
https://listmaster.pepperfish.net/pipermail/baserock-dev-baserock.org/2017-June/013797.html

[3]. This is the current version of 'convert': 
https://gitlab.com/baserock/definitions/blob/5bd42c0de85e9adccd9b7de0e2a9b0ec71ac02d4/convert
-- 
Sam Thursfield, Codethink Ltd.
Office telephone: +44 161 236 5575



More information about the baserock-dev mailing list