From owner-freebsd-current@FreeBSD.ORG Sat Nov 19 13:43:14 2005 Return-Path: X-Original-To: freebsd-current@freebsd.org Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id F273F16A41F for ; Sat, 19 Nov 2005 13:43:13 +0000 (GMT) (envelope-from nb_root@videotron.ca) Received: from relais.videotron.ca (relais.videotron.ca [24.201.245.36]) by mx1.FreeBSD.org (Postfix) with ESMTP id 95D7B43D4C for ; Sat, 19 Nov 2005 13:43:05 +0000 (GMT) (envelope-from nb_root@videotron.ca) Received: from clk01a ([66.130.198.54]) by VL-MO-MR001.ip.videotron.ca (Sun Java System Messaging Server 6.2-2.05 (built Apr 28 2005)) with ESMTP id <0IQ700CHBFFRONK0@VL-MO-MR001.ip.videotron.ca> for freebsd-current@freebsd.org; Sat, 19 Nov 2005 08:43:04 -0500 (EST) Date: Sat, 19 Nov 2005 08:42:57 -0500 From: Nicolas Blais In-reply-to: <20051116175853.GA899@schweikhardt.net> To: Jens Schweikhardt Message-id: <200511190843.03660.nb_root@videotron.ca> MIME-version: 1.0 Content-type: multipart/signed; boundary=nextPart2354365.1k5VlyUzhj; protocol="application/pgp-signature"; micalg=pgp-sha1 Content-transfer-encoding: 7bit References: <200511141702.45491.nb_root@videotron.ca> <200511151942.04277.nb_root@videotron.ca> <20051116175853.GA899@schweikhardt.net> User-Agent: KMail/1.8.3 Cc: Steve Hodgson , Maxim.Sobolev@portaone.com, michael johnson , freebsd-current@freebsd.org Subject: Re: Using ccache for build{world, kernel} X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 19 Nov 2005 13:43:14 -0000 --nextPart2354365.1k5VlyUzhj Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline > The ccache port is not broken. Rather, the assumption that any port can > deal with CC=3D"foo bar" is wrong. Some ports choke because they've never > seen a CC like that (libtool15 comes to mind), some may choke because > their build can't deal with a space in a program name (shell word splitti= ng > at the wrong time or not at all is a likely culprit). Some insist on > their own special-tailored compiler (openoffice). The build hackery out > there in 13000 ports is unbelievably, uh, creative. To avoid all of these > issues you have to replace all of /usr/bin/{cc,c++,gcc,g++,...} and > /usr/local/bin/gcc-ooo and that ilk with a symlink to /usr/local/bin/ccac= he > and put the real compilers in some other directory. In other words, the > ccache installation is as transparent as can be. The various builds don't > even know that they are using ccache when they run /usr/bin/cc and you > don't need any CC, CXX or PATH sequence hackery. Usually this means to set > CCACHE_PATH which collides with the needs of a "make buildworld". So, you > really need two different strategies, one when building > world/kernel, and one for all other purposes. That's what I do right now > and so far I have no problems with ports and ccache. > > Regards, > > Jens Okay, but is /usr/local/share/doc/ccache/ccache-howto-freebsd.txt still val= id? =20 Such as :=20 To use ccache add the following to /etc/make.conf =2Eif !defined(NOCCACHE) =2Eif ${.CURDIR:M/usr/src*} CC=3D/usr/local/libexec/ccache/cc CXX=3D/usr/local/libexec/ccache/c++ =2Eelse CC=3Dcc CXX=3Dc++ =2Eendif =2Eelse CC=3D/usr/bin/cc CXX=3D/usr/bin/c++ =2Eendif I'm asking because I'm slightly confused (sorry) as some people tell me to = not=20 put the block in /etc/make.conf. If I don't put anything, my .ccache folde= r=20 remains empty (therefore ccache not being used).=20 Whatever the real usage of ccache, it should be mentionned in that file, or= =20 during 'make install' as a pkg-message. Thanks, Nicolas. =2D-=20 =46reeBSD 7.0-CURRENT #0: Tue Nov 15 06:21:56 EST 2005 =20 root@clk01a:/usr/obj/usr/src/sys/CLK01A=20 PGP? (updated 16 Nov 05) : http://www.clkroot.net/security/nb_root.asc --nextPart2354365.1k5VlyUzhj Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (FreeBSD) iD8DBQBDfyvn4wTBlvcsbJURAl0cAKDEX7fGd6f2eD6DJl7XDSur3nVYkACfcGMO 7ndJc6+Zth6fBtuCxAgGiew= =7H5V -----END PGP SIGNATURE----- --nextPart2354365.1k5VlyUzhj--