ccache is a compiler cache. It speeds up re-compilation of C/C++ code by caching previous compiles and detecting when the same compile is being done again.

The following is a step by step guide to how to enable and use ccache on FreeBSD 7.1:

  1. su
  2. # cd /usr/ports/devel/ccache
  3. # make install clean
  4. # vim /etc/make.conf

.if (!empty(.CURDIR:M/usr/src*) || !empty(.CURDIR:M/usr/obj*)) && !defined(NOCCACHE)




Basically we’ve started by installing ccache (steps 1 through 3) and proceeded by editing /etc/make.conf as to enable ccache on builds.

Now we need to update the environment.

Further instructions here

Source: (19/01/2009)