From owner-freebsd-toolchain@FreeBSD.ORG Thu Feb 12 00:02:20 2015 Return-Path: Delivered-To: freebsd-toolchain@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 7EFB4BB4 for ; Thu, 12 Feb 2015 00:02:20 +0000 (UTC) Received: from iredmail.onthenet.com.au (iredmail.onthenet.com.au [203.13.68.150]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 391581BE for ; Thu, 12 Feb 2015 00:02:19 +0000 (UTC) Received: from localhost (iredmail.onthenet.com.au [127.0.0.1]) by iredmail.onthenet.com.au (Postfix) with ESMTP id 05CCB281111 for ; Thu, 12 Feb 2015 10:02:17 +1000 (EST) X-Amavis-Modified: Mail body modified (using disclaimer) - iredmail.onthenet.com.au X-Virus-Scanned: amavisd-new at iredmail.onthenet.com.au Received: from iredmail.onthenet.com.au ([127.0.0.1]) by localhost (iredmail.onthenet.com.au [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Gro69zOHY31z for ; Thu, 12 Feb 2015 10:02:16 +1000 (EST) Received: from Peters-MacBook-Pro.local (unknown [64.245.0.210]) by iredmail.onthenet.com.au (Postfix) with ESMTPSA id BBD3B280F55; Thu, 12 Feb 2015 10:02:13 +1000 (EST) Message-ID: <54DBED83.8070204@freebsd.org> Date: Wed, 11 Feb 2015 16:02:11 -0800 From: Peter Grehan User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:31.0) Gecko/20100101 Thunderbird/31.4.0 MIME-Version: 1.0 To: Baptiste Daroussin , Warner Losh Subject: Re: Resurrecting clang external toolchain support in Makefile.inc References: <54DABF3A.8060003@freebsd.org> <20150211084534.GY29891@ivaldir.etoilebsd.net> In-Reply-To: <20150211084534.GY29891@ivaldir.etoilebsd.net> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-toolchain@freebsd.org X-BeenThere: freebsd-toolchain@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Maintenance of FreeBSD's integrated toolchain List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 12 Feb 2015 00:02:20 -0000 Hi Bapt, > In my opinion we should track down the last traces of XFLAGS and turn them into > proper XCFLAGS and XCXXFLAGS, the intent was to get rid of XFLAGS because the > name was confusing. > > so instead of adding XFLAGS to XC*FLAGS, the XFLAGS should juste be converted > into XC*FLAGS directly in my opinion. How about the appended ? It moves the sysroot definition into the non-GCC XC/XCXXFLAGS defs, and renames XFLAGS to BFLAGS. This should be identical to pre r273755 behaviour. later, Peter. --- Makefile.inc1 (revision 278542) +++ Makefile.inc1 (working copy) @@ -348,16 +348,15 @@ SIZE="${XSIZE}" .if ${XCC:M/*} -XFLAGS= --sysroot=${WORLDTMP} .if defined(CROSS_BINUTILS_PREFIX) # In the case of xdev-build tools, CROSS_BINUTILS_PREFIX won't be a # directory, but the compiler will look in the right place for it's # tools so we don't need to tell it where to look. .if exists(${CROSS_BINUTILS_PREFIX}) -XFLAGS+= -B${CROSS_BINUTILS_PREFIX} +BFLAGS+= -B${CROSS_BINUTILS_PREFIX} .endif .else -XFLAGS+= -B${WORLDTMP}/usr/bin +BFLAGS+= -B${WORLDTMP}/usr/bin .endif .if ${TARGET} == "arm" .if ${TARGET_ARCH:M*hf*} != "" @@ -374,6 +373,8 @@ TARGET_ABI?= unknown TARGET_TRIPLE?= ${TARGET_ARCH:C/amd64/x86_64/}-${TARGET_ABI}-freebsd11.0 XCFLAGS+= -target ${TARGET_TRIPLE} +XCFLAGS+= --sysroot=${WORLDTMP} ${BFLAGS} +XCXXFLAGS+= --sysroot=${WORLDTMP} ${BFLAGS} .endif .endif