From owner-freebsd-ppc@FreeBSD.ORG Fri Jun 27 06:22:45 2014 Return-Path: Delivered-To: freebsd-ppc@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 16B60850; Fri, 27 Jun 2014 06:22:45 +0000 (UTC) Received: from zibbi.meraka.csir.co.za (zibbi.meraka.csir.co.za [IPv6:2001:4200:7000:2::1]) by mx1.freebsd.org (Postfix) with ESMTP id 093AE26A0; Fri, 27 Jun 2014 06:22:44 +0000 (UTC) Received: by zibbi.meraka.csir.co.za (Postfix, from userid 3973) id 1DB63B84D; Fri, 27 Jun 2014 08:22:41 +0200 (SAST) Date: Fri, 27 Jun 2014 08:22:41 +0200 From: John Hay To: Baptiste Daroussin Subject: Re: Boost 1.55.0 (Was: Re: PowerPC Packages) Message-ID: <20140627062240.GA65987@zibbi.meraka.csir.co.za> References: <20140625073340.GA57075@FreeBSD.org> <20140625072305.45baf39b@zhabar.att.net> <20140626100258.GA47002@FreeBSD.org> <53AC3DB2.3070902@freebsd.org> <20140626154416.GD24440@ivaldir.etoilebsd.net> <53AC5AA1.1030508@freebsd.org> <20140626190050.GE24440@ivaldir.etoilebsd.net> <53AC6E8E.7050700@freebsd.org> <20140626213333.GG24440@ivaldir.etoilebsd.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20140626213333.GG24440@ivaldir.etoilebsd.net> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: FreeBSD PowerPC ML , FreeBSD Mailing List , Justin Hibbits X-BeenThere: freebsd-ppc@freebsd.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Porting FreeBSD to the PowerPC List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 27 Jun 2014 06:22:45 -0000 On Thu, Jun 26, 2014 at 11:33:33PM +0200, Baptiste Daroussin wrote: > On Thu, Jun 26, 2014 at 12:03:42PM -0700, Nathan Whitehorn wrote: > > > > On 06/26/14 12:00, Baptiste Daroussin wrote: > > > On Thu, Jun 26, 2014 at 11:30:39AM -0700, Justin Hibbits wrote: > > >> On Thu, Jun 26, 2014 at 10:38 AM, Nathan Whitehorn > > >> wrote: > > >>> On 06/26/14 08:44, Baptiste Daroussin wrote: > > >>>> On Thu, Jun 26, 2014 at 08:35:14AM -0700, Nathan Whitehorn wrote: > > >>>>> On 06/26/14 03:02, Alexey Dokuchaev wrote: > > >>>>>> On Wed, Jun 25, 2014 at 07:23:05AM -0700, Justin Hibbits wrote: > > >>>>>>> As I mentioned earlier, you can set "FAVORITE_COMPILER=gcc" in > > >>>>>>> make.conf, and it'll build with gcc47. > > >>>>>> FAVORITE_COMPILER looks more like a hack to me. Ideally boost's port > > >>>>>> Makefile should be fixed instead. > > >>>>>> > > >>>>>> I also would rather use system compiler (whether it's gcc4.2 or clang) > > >>>>>> instead of gcc47. > > >>>>>> > > >>>>>> ./danfe > > >>>>>> > > >>>>> Yes, it should be made to respect whatever cc is. > > >>>> As long as cc is supported upstream, boost being a nightmare to maintain I > > >>>> will > > >>>> reject all patches that are not accepted upstream first, otherwise bumping > > >>>> to > > >>>> 1.56 will be painful. > > >>>> > > >>>> That said I fully support the effort. > > >>>> > > >>>> regards, > > >>>> Bapt > > >>> > > >>> The following patch fixes the issue for me (as well as several other ports). > > >>> I'll let you decide whether this is how you want to handle the problem. > > >>> -Nathan > > >>> > > >>> Index: Mk/Uses/compiler.mk > > >>> =================================================================== > > >>> --- Mk/Uses/compiler.mk (revision 358026) > > >>> +++ Mk/Uses/compiler.mk (working copy) > > >>> @@ -75,7 +75,9 @@ > > >>> ALT_COMPILER_TYPE= none > > >>> _ALTCCVERSION= > > >>> .if ${COMPILER_TYPE} == gcc && exists(/usr/bin/clang) > > >>> +.if ${ARCH} == amd64 || ${ARCH} == i386 # clang often non-default for a > > >>> reason > > >>> _ALTCCVERSION!= /usr/bin/clang --version > > >>> +.endif > > >>> .elif ${COMPILER_TYPE} == clang && exists(/usr/bin/gcc) > > >>> _ALTCCVERSION!= /usr/bin/gcc --version > > >>> .endif > > >>> @@ -138,7 +140,7 @@ > > >>> > > >>> .if ${_COMPILER_ARGS:Mc++11-lang} > > >>> .if !${COMPILER_FEATURES:Mc++11} > > >>> -.if defined(FAVORITE_COMPILER) && ${FAVORITE_COMPILER} == gcc > > >>> +.if (defined(FAVORITE_COMPILER) && ${FAVORITE_COMPILER} == gcc) || (${ARCH} > > >>> != amd64 || ${ARCH} != i386) # clang not always supported on Tier-2 > > >>> USE_GCC= yes > > >>> CHOSEN_COMPILER_TYPE= gcc > > >>> .elif (${COMPILER_TYPE} == clang && ${COMPILER_VERSION} < 33) || > > >>> ${COMPILER_TYPE} == gcc > > >>> > > >> bapt mentioned a while back about separating the concept of the 'base > > >> compiler' and 'ports compiler'. Perhaps we need to explore this > > >> again. It should be possible to mark ports as being dependencies for > > >> the ports compiler, and all other ports would get built by said > > >> compiler, while those are built by the base compiler. This way we can > > >> take advantage of any enhancements we might get with a newer compiler > > >> (like better altivec support and autovectorization from newer gcc, > > >> better optimizations, etc). > > >> > > >> - Justin > > > nathan, I all for what you did, except that we should also add arm to the clang > > > list ;) > > > > I think that should work automatically. Isn't clang cc on ARM? This only > > has an affect if cc is gcc and clang is also installed. The assumption > > is that clang is non-default for a reason in such cases (except for > > stable/10 x86, which is special-cased). > > -Nathan Are all ARMs equal? root@cambria-build:~ # uname -p armeb root@cambria-build:~ # uname -m arm root@cambria-build:~ # uname -a FreeBSD cambria-build 11.0-CURRENT FreeBSD 11.0-CURRENT #1 r267739M: Mon Jun 23 07:10:57 SAST 2014 jhay@dolphin.meraka.csir.co.za:/usr/obj/arm.armeb/snaps/arm/11-tst/src/sys/CAMBRIA arm root@cambria-build:~ # cc --version cc (GCC) 4.2.1 20070831 patched [FreeBSD] Copyright (C) 2007 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. Not that I think I want to compile boost on it. :-) John -- John Hay -- jhay@meraka.csir.co.za / jhay@meraka.org.za