the documentation installed at /usr/local/share/doc/ccache/ccache-howto-freebsd.txt seems to provide incorrect directions for using ccache to build your world and kernel. specifically it seems you only need to update /etc/src.conf to enable ccache as opposed to the older approach of using make.conf. furthermore using the instructions bellow no longer seem to work. this diff updates the documentation to refer to the current need to only update /etc/src.conf to successfully utilize ccache for buildworld and buildkernel: $ diff -u devel/ccache/files/ccache-howto-freebsd.txt.in.bak devel/ccache/files/ccache-howto-freebsd.txt.in --- devel/ccache/files/ccache-howto-freebsd.txt.in.bak 2017-10-03 17:05:38.657820000 -0700 +++ devel/ccache/files/ccache-howto-freebsd.txt.in 2017-10-03 17:07:07.420574000 -0700 @@ -6,27 +6,11 @@ /etc/make.conf. The rest of this guide is for building /usr/src and other checkouts. -To use ccache for base add the following to /etc/make.conf. -You can replace cc and c++ with the compilers of your choice. -(remember that only GCC and Clang can build world and kernel) +To use ccache for base add the following to /etc/src.conf. +WITH_CCACHE_BUILD=true -.if (!empty(.CURDIR:M/usr/src*) || !empty(.CURDIR:M/usr/obj*)) -.if !defined(NOCCACHE) && exists(%%PREFIX%%/%%CCLINKDIR%%/world/cc) -CC:=${CC:C,^cc,%%PREFIX%%/%%CCLINKDIR%%/world/cc,1} -CXX:=${CXX:C,^c\+\+,%%PREFIX%%/%%CCLINKDIR%%/world/c++,1} -.endif -.endif - -For Korn/Bourne shells Add the following to /etc/profile: - export PATH=%%PREFIX%%/%%CCLINKDIR%%:$PATH - export CCACHE_PATH=/usr/bin:%%LOCALBASE%%/bin - -For csh/tcsh Add the following to /etc/csh.cshrc: - setenv PATH %%PREFIX%%/%%CCLINKDIR%%:$PATH - setenv CCACHE_PATH /usr/bin:%%LOCALBASE%%/bin - -For icc users: - Add %%ICCPREFIX%% to CCACHE_PATH +Refer to src.conf(5) for more detailed instructions on using +ccache to build the base system. --
Thanks, fixed based on your patch.
A commit references this bug: Author: bdrewery Date: Tue May 8 19:12:17 UTC 2018 New revision: 469389 URL: https://svnweb.freebsd.org/changeset/ports/469389 Log: Update howto - 11.0+ base can just use WITH_CCACHE_BUILD=yes [1] - Remove older advise for libtool which is no longer needed - No need for clang unused argument hack anymore PR: 222765 [1] Submitted by: pete@nomadlogic.org [1] (based on) Changes: head/devel/ccache/Makefile head/devel/ccache/files/ccache-howto-freebsd.txt.in
A commit references this bug: Author: bdrewery Date: Tue May 8 19:14:51 UTC 2018 New revision: 469390 URL: https://svnweb.freebsd.org/changeset/ports/469390 Log: MFH: r469300 r469389 Add clang60 support Update howto - 11.0+ base can just use WITH_CCACHE_BUILD=yes [1] - Remove older advise for libtool which is no longer needed - No need for clang unused argument hack anymore PR: 222765 [1] Submitted by: pete@nomadlogic.org [1] (based on) Approved by: portmgr (implicit) Changes: _U branches/2018Q2/ branches/2018Q2/devel/ccache/Makefile branches/2018Q2/devel/ccache/files/ccache-howto-freebsd.txt.in