From owner-freebsd-current@FreeBSD.ORG Tue Aug 30 17:37:39 2011 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B394B106566B for ; Tue, 30 Aug 2011 17:37:39 +0000 (UTC) (envelope-from ohartman@zedat.fu-berlin.de) Received: from outpost1.zedat.fu-berlin.de (outpost1.zedat.fu-berlin.de [130.133.4.66]) by mx1.freebsd.org (Postfix) with ESMTP id 6F28C8FC0A for ; Tue, 30 Aug 2011 17:37:39 +0000 (UTC) Received: from inpost2.zedat.fu-berlin.de ([130.133.4.69]) by outpost1.zedat.fu-berlin.de (Exim 4.69) with esmtp (envelope-from ) id <1QySFm-0007AJ-Ls>; Tue, 30 Aug 2011 19:37:38 +0200 Received: from e178029245.adsl.alicedsl.de ([85.178.29.245] helo=thor.walstatt.dyndns.org) by inpost2.zedat.fu-berlin.de (Exim 4.69) with esmtpsa (envelope-from ) id <1QySFm-0000lN-Ir>; Tue, 30 Aug 2011 19:37:38 +0200 Message-ID: <4E5D1FE2.8080607@zedat.fu-berlin.de> Date: Tue, 30 Aug 2011 19:37:38 +0200 From: "Hartmann, O." User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:6.0) Gecko/20110825 Thunderbird/6.0 MIME-Version: 1.0 To: Dimitry Andric References: <4E5CB1E9.9080801@zedat.fu-berlin.de> <4E5D0DD3.20606@FreeBSD.org> In-Reply-To: <4E5D0DD3.20606@FreeBSD.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: 85.178.29.245 Cc: freebsd-current Subject: Re: CLANG; still cc in use when building the WORLD with CLANG? 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: Tue, 30 Aug 2011 17:37:39 -0000 On 08/30/11 18:20, Dimitry Andric wrote: > On 2011-08-30 11:48, Hartmann, O. wrote: >> I'm building world with CLANG (or I pretend to do so). >> In my /etc/make.conf I use these lines: >> ### >> ### CLANG >> ### >> .if defined(USE_CLANG) >> .if !empty(.CURDIR:M/usr/src*) > > You should add "|| !empty(.CURDIR:M:/usr/obj*)" to this .if statement, > because the build build process changes to directories inside /usr/obj > for various steps. Alternatively, use the simpler: > > .if empty(.CURDIR:N/usr/src*:N/usr/obj*) > > Alternatively, just remove the statement, and use clang for everything, > and help fix bugs in ports. :) > :-) I would, if I did not desperately have to rely on a working box for now. I forgot the above addition. Will try it - or better, leave it alone and try helping buxfixing ... > >> CFLAGS= -O3 -march=native -mtune=native -fno-strict-aliasing -pipe >> COPTFLAGS= -O3 -march=native -mtune=native -pipe > > Take care when using clang and -march=native, there are still some > issues with it (search this mailing list for specifics). If anything > goes wrong, first revert to the default CFLAGS and COPTFLAGS (e.g. > comment them out), and try again. Yes, I know, but I never had problems on my older Core2 based chips. The newer laptop CPU, a Core-i5 "Lynnfield" does have issues.