RFC: Building RTEMS/RISC-V with LLVM/Clang

Hesham Almatary hesham.almatary at cl.cam.ac.uk
Thu Oct 24 14:32:15 UTC 2019

Hi Sebastian,

On Thu, 24 Oct 2019 at 12:48, Sebastian Huber
<sebastian.huber at embedded-brains.de> wrote:
> Hello,
> I work currently on a new build system based on waf and Doorstop. It
> would be good to have the clang support at the top level of the build
> system. Doing this for the current build system is probably a waste of
> time. In general, I am fine with your changes.
I agree autotools isn't that great with llvm/clang, but the changes aren't
that much and it would be nice to CI from upstream RTEMS rather than
my fork.

> It would be great if you could try to figure out how this works with
> waf. Please let me know if you have time for this.
Sure, that's a good opportunity to learn about waf, so I'll give it a try.

> You can find a prototype implementation of the new build system here:
> https://git.rtems.org/sebh/rtems.git/commit/?h=build
> I do forced pushes to this branch.
> You can test it with:
> git clone git://git.rtems.org/sebh/rtems.git
> cd rtems
> git checkout --track origin/build
> ./waf bsp_defaults --rtems-bsps=riscv > bsps.ini
> ./waf configure
> ./waf
> Adding the clang support could be done with a command line option, see
> function options() in wscript. Depending on the option, clang instead of
> gcc must be found in configure().
Thanks for the hints. I'll give it a go.

> --
> Sebastian Huber, embedded brains GmbH
> Address : Dornierstr. 4, D-82178 Puchheim, Germany
> Phone   : +49 89 189 47 41-16
> Fax     : +49 89 189 47 41-09
> E-Mail  : sebastian.huber at embedded-brains.de
> PGP     : Public key available on request.
> Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.

More information about the devel mailing list