Re: Caching build objects: Waf and ccache

2021-10-10 Thread Thomas Nagy
Are you looking for general instructions or are you trying to optimize the 
rtems build?

To wrap the compiler using ccache, override the environment variables during 
the configuration:
CXX='ccache gxx' CC='ccache gcc' waf configure

The rtems manual does not advertise it, so it this may void your warranty:
CC="ccache /home/user/quick-start/rtems/6/bin/sparc-rtems6-gcc" ./waf configure 
--prefix=$HOME/quick-start/rtems/6

The wafcache extension is a different system: if the wafcache.py is added to a 
project (it is not a default option yet), all build results (link, results, 
manual pages) become shareable using a filesystem directory or over the 
network. It is probably unnecessary to import it in rtems unless you are 
addressing a specific performance issue.

Thomas

On Tue, 5 Oct 2021 11:17:26 +0200, Stanislav Pankevich  
wrote:

> Hello everyone,
> 
> I have a very specific question about the Waf build system. I apologize if
> I missed this information somewhere in the documentation.
> 
> From looking at ./waf --help it doesn't look like Waf would have a
> ccache-like functionality built in.
> 
> When using CMake build system, I am used to providing
> 
> -DCMAKE_CXX_COMPILER_LAUNCHER=ccache
> 
> that makes CMake switch to using ccache. Is there an equivalent option for
> Waf or is there a native way in Waf for caching object artifacts?
> 
> Thank you,
> 
> Stanislav
> ___
> users mailing list
> users@rtems.org
> http://lists.rtems.org/mailman/listinfo/users



___
users mailing list
users@rtems.org
http://lists.rtems.org/mailman/listinfo/users


Re: Caching build objects: Waf and ccache

2021-10-05 Thread Stanislav Pankevich
Thanks for the answer. My comments below:

On Tue, Oct 5, 2021 at 11:50 AM Sebastian Huber <
sebastian.hu...@embedded-brains.de> wrote:

> Hello Stanislav,
>
> On 05/10/2021 11:17, Stanislav Pankevich wrote:
> > I have a very specific question about the Waf build system. I apologize
> if
> > I missed this information somewhere in the documentation.
> >
> >  From looking at ./waf --help it doesn't look like Waf would have a
> > ccache-like functionality built in.
> >
> > When using CMake build system, I am used to providing
> >
> > -DCMAKE_CXX_COMPILER_LAUNCHER=ccache
> >
> > that makes CMake switch to using ccache. Is there an equivalent option
> for
> > Waf or is there a native way in Waf for caching object artifacts?
>
> you may have a look at this:
>
> https://gitlab.com/ita1024/waf/blob/master/waflib/extras/wafcache.py
>
>
Thanks for the pointer!

I don't know if this works with RTEMS. Do you want to use this for the
> RTEMS build? I am not sure if it is worth the trouble since RTEMS builds
> in a couple of seconds.
>

Yes, we would like to have caching specifically for building RTEMS using
Waf. The upper layers of our software are built with ccache enabled in
CMake.

Building RTEMS and BSP for Zynq 7020 is taking ~60 seconds on our GitLab
Runner VM (1460 files). We are building from the default instructions (2.5.
Build a Board Support Package (BSP)), we might remove the test suites
eventually but the build time is already noticeable.

Thanks.
___
users mailing list
users@rtems.org
http://lists.rtems.org/mailman/listinfo/users


Re: Caching build objects: Waf and ccache

2021-10-05 Thread Sebastian Huber

Hello Stanislav,

On 05/10/2021 11:17, Stanislav Pankevich wrote:

I have a very specific question about the Waf build system. I apologize if
I missed this information somewhere in the documentation.

 From looking at ./waf --help it doesn't look like Waf would have a
ccache-like functionality built in.

When using CMake build system, I am used to providing

-DCMAKE_CXX_COMPILER_LAUNCHER=ccache

that makes CMake switch to using ccache. Is there an equivalent option for
Waf or is there a native way in Waf for caching object artifacts?


you may have a look at this:

https://gitlab.com/ita1024/waf/blob/master/waflib/extras/wafcache.py

I don't know if this works with RTEMS. Do you want to use this for the 
RTEMS build? I am not sure if it is worth the trouble since RTEMS builds 
in a couple of seconds.


--
embedded brains GmbH
Herr Sebastian HUBER
Dornierstr. 4
82178 Puchheim
Germany
email: sebastian.hu...@embedded-brains.de
phone: +49-89-18 94 741 - 16
fax:   +49-89-18 94 741 - 08

Registergericht: Amtsgericht München
Registernummer: HRB 157899
Vertretungsberechtigte Geschäftsführer: Peter Rasmussen, Thomas Dörfler
Unsere Datenschutzerklärung finden Sie hier:
https://embedded-brains.de/datenschutzerklaerung/
___
users mailing list
users@rtems.org
http://lists.rtems.org/mailman/listinfo/users

Caching build objects: Waf and ccache

2021-10-05 Thread Stanislav Pankevich
Hello everyone,

I have a very specific question about the Waf build system. I apologize if
I missed this information somewhere in the documentation.

>From looking at ./waf --help it doesn't look like Waf would have a
ccache-like functionality built in.

When using CMake build system, I am used to providing

-DCMAKE_CXX_COMPILER_LAUNCHER=ccache

that makes CMake switch to using ccache. Is there an equivalent option for
Waf or is there a native way in Waf for caching object artifacts?

Thank you,

Stanislav
___
users mailing list
users@rtems.org
http://lists.rtems.org/mailman/listinfo/users