rsb (RTEMS source Builder) support for local mirrors ?

Chris Johns chrisj at rtems.org
Tue Apr 27 03:14:40 UTC 2021


On 27/4/21 4:07 am, Michael Davidsaver wrote:
> On 4/26/21 1:21 AM, Goetz Pfeiffer wrote:
>> Hello,
>>
>> I have used rsb to build my local cross compiler toolchain for RTEMS.
>>
>> This is a great tool, but it downloads all sources from some internet servers. The problem is
>> that servers may be down at the time I need them or that the locations of some files have changed
>> and rsb doesn't know about this.
>>
>> Would it be possible to change rsb in a way that it has an option to download all needed files from a
>> local mirror ?
> 
> I've had some success with running the RSB recipes twice.  First with '--source-only-download',
> and then again with '--no-download'.  The second time uses previously downloaded files,
> and can be run on a offline host.

Does the `--url` option work? It should point you to a local server.

A better or more complete way to handle tools is to "deploy" them. Deployed
tools lets you add a version label into the tools that can be seen with the
standard version option the tools come with. There is a real benefit to having a
special label in the version for deployed tool sets especially binary packages.

Unfortunately I have not had the time to document how to do this so here is a
brief untested procedure. It is pretty much what the release procedure does:

1. Clone or download the RSB source.

2. Add or edit a VERSION file in the top level of the RSB source. The 5.1
release tarball of the RSB has a version file.

3. Run the `sb-get-sources` command to fetch all the source and patches.

4. Package the RSB, source and patches.

Notes:

a) The format for the VERSION file is documented here:

https://git.rtems.org/rtems-source-builder/tree/source-builder/sb/version.py#n31

b) The release process creates the VERSION file here:

https://git.rtems.org/rtems-release/tree/rtems-release-rsb-version

c) The get sources command is better than the download options because it
downloads all patches for all archs and all hosts. This is a requirement for
releasing.

d) Released sources contain a released RTEMS kernel and RTEMS Tools and this
requires special management of the checksum the RSB uses when building from a
source package. The hashes for these packages are placed in the VERSION file.
The 5.1 release shows how this is done.

e) A simple and clean way to deploy ...  clone the release scripts and run them
:) Joel has patches for Linux he is yet to post so pester him if you would like
to follow this path. The release scripts handle the release path for downloading
and special release labels. The release procedure is open and available for just
this purpose.

>> In my case I would need this feature not just for version 5 of RTEMS but also for version
>> 4.9 and 4.10.

RTEMS 4.9, 4.10, and 4.11 would need some work to bring it inline with 5 to
support deployment. That work would need to be funded so if this is something
you need please contact me off list.

Chris


More information about the users mailing list