8 Core processor, -j 9 flag, where?

Hello folks, thank your taking the time to read and answer. On the Absolute FreeBSD book, I read there's somewhere I can pass the compiler the flag "-j 9", I just don't remember which file it was and I don't have the book with me. And it would be cool to use 100% of my CPU. Since I'm rebuilding software a lot from ports. Still getting the hang of it.
 
In /etc/make.conf:
Code:
MAKE_JOBS_NUMBER?=8

Some ports can't do parallel builds.

For operating system builds:
Code:
# cd /usr/src
# make -j9 buildworld

Benchmark that. If you want it to go fast, install devel/ccache and benchmark it. After it is mostly in cache, the builds will go much faster.
 
I would also suggest taking a look at sysutils/bsdadminscripts. Description:
a collection of administration scripts. At the moment it consists of a script to control rc.d scripts at runtime, a script that runs common make targets on batches of ports, scripts to set variables for make jobs (like portconf, but with more possibilities). And scripts to check for broken packages and missing libraries.
The pertinent part to your question is that it provides the file /usr/local/buildflags.conf, where you can specify port-by-port build specs. It's important because during updates (portmaster -a for example) some ports will refuse MAKE_JOBS and break because of it. This solution allows you to set exceptions and sit back as ports get built without interruption.
 
Back
Top