facebook/openbmc

Yocto Build time improvements?

dhanna11 opened this issue · 1 comments

Hi,

I was wondering if Facebook (or anyone else) has done any experimentation with improving the build times of Yocto based projects.

I'm slowly working to migrate some of our projects from Makefiles to Skylark, but I don't have a clue what to do about our Yocto stuff, besides shelling it out...

Hi @dhanna11 - There isn't anything in particular about Yocto that is slow (or faster) other than it is calling all the underlying build to rebuild all the packages (and toolchain) that you need. There is quite a bit of caching that can be done though. Take a look at the "shared state cache" section in the Yocto manual: https://www.yoctoproject.org/docs/latest/mega-manual/mega-manual.html#shared-state-cache

What we do is periodically run a job on a big server that creates the sstate cache for all of our supported configurations. ~20 machines takes ~3 hrs to run. For our CI jobs we can then download an archive of the sstate cache and pull-request builds end up being about 10-15 minutes (per supported configuration).