1Use 2.Xr ccache 1 3for the build. 4No configuration is required except to install the 5.Sy devel/ccache 6or 7.Sy devel/sccache 8package. 9When using with 10.Xr distcc 1 , 11set 12.Sy CCACHE_PREFIX=/usr/local/bin/distcc . 13When using with sccache 14set 15.Sy CCACHE_NAME=sccache 16in 17.Xr src.conf 5 . 18The default cache directory of 19.Pa $HOME/.ccache 20will be used, which can be overridden by setting 21.Sy CCACHE_DIR . 22The 23.Sy CCACHE_COMPILERCHECK 24option defaults to 25.Sy content 26when using the in-tree bootstrap compiler, 27and 28.Sy mtime 29when using an external compiler. 30The 31.Sy CCACHE_CPP2 32option is used for Clang but not GCC. 33.Pp 34Sharing a cache between multiple work directories requires using a layout 35similar to 36.Pa /some/prefix/src 37.Pa /some/prefix/obj 38and an environment such as: 39.Bd -literal -offset indent 40CCACHE_BASEDIR='${SRCTOP:H}' MAKEOBJDIRPREFIX='${SRCTOP:H}/obj' 41.Ed 42.Pp 43See 44.Xr ccache 1 45for more configuration options. 46