Portmaster and make flags

Hello,

Can someone tell me how (or if I should) pass the -j make flag to portmaster as I'm now using a multi-core machine.

Thanks.
 
To compile kernel and world in parallel manner I use the -j flag on 4-core machine:

Code:
cd /usr/src && make cleanworld && make -j8 buildworld && make -j8 kernel
 
I think you're supposed to feed (cores + 1) to -j, not (cores * 2).
 
The "rule of thumb" is (cores + 1). However, it's very dependent on the system, and some local testing will show the optimal number. Some machines work better with more than (cores + 1). Others work better with less.

Running [cmd=]time -h make -j X buildworld[/cmd] with different values of X is quite enlightening. Especially if you put /usr/obj onto a separate filesystem and newfs it between runs (and reboot to clear out RAM).
 
Back
Top