Speed Up Compilation with the “–jobs” Make Option

Here’s a quick, simple tip to speed up the time it takes to compile a kernel or other program with a well designed Makefile (i.e. BusyBox): use the --jobs or -j make option. This will allow the compiler to execute in parallel in what’s known as recipes. Here’s a quick example for compiling a kernel zImage bootable image:

make -j4 zImage

This will spawn off 4 parallel compiling processes. There is not a limit for the number of job slots that you can use, but I’ve been told that as a general rule of thumb not to exceed more than twice the number of CPU cores you have. I don’t have any references (or extensive experience) to back that up, so take it for what it’s worth.

For more information, see the following resource:

Feel free to donate if this post prevented any headaches! Another way to show your appreciation is to take a gander at these relative ads that you may be interested in:

There's 0 Comment So Far

Share your thoughts, leave a comment!