From owner-freebsd-current@FreeBSD.ORG Wed Feb 13 04:02:43 2013 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 531106C for ; Wed, 13 Feb 2013 04:02:43 +0000 (UTC) (envelope-from bf1783@googlemail.com) Received: from mail-ie0-x232.google.com (mail-ie0-x232.google.com [IPv6:2607:f8b0:4001:c03::232]) by mx1.freebsd.org (Postfix) with ESMTP id 2969D91D for ; Wed, 13 Feb 2013 04:02:43 +0000 (UTC) Received: by mail-ie0-f178.google.com with SMTP id c13so1180133ieb.9 for ; Tue, 12 Feb 2013 20:02:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20120113; h=mime-version:x-received:reply-to:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=d9aczsZLPQsoVS4qYB59rbjCB2s2tM1/7XgnmK9RxgE=; b=P43ZetbpTTAi94Xg66lalBh5tMsJPJK+3+2WYVC++Ly1T7/nv0K7QPbCFlM5S5E+Lb dOitX4JLQz3unI6dQkC+LVernhZlPUUm+9XCylEpolqtcofcQLFqcJSFmisFkuEL/TOA z9dVaUs15folMFEJNcy4uzC/EL6/FI4xiWMgIqk5FWJDhsfDwLU62kUgnfRZh3p9rfdV uOHOH9PS8K8PzUl2o8V8lL7VX0y1CsbaKFdX/Sy9nVP72CB8z+8swHgEXtUsP/3Oj6HF wsYST2wcTCE4vh9rYhHUdFApKUtPPG/Obuc4oG8sPseV2foKuMmh4R0SxMUltZpEsHE1 yMOg== MIME-Version: 1.0 X-Received: by 10.50.179.100 with SMTP id df4mr8389441igc.60.1360728162841; Tue, 12 Feb 2013 20:02:42 -0800 (PST) Received: by 10.64.44.2 with HTTP; Tue, 12 Feb 2013 20:02:42 -0800 (PST) In-Reply-To: <20130213033933.GA89757@troutmask.apl.washington.edu> References: <20130213014734.GA89321@troutmask.apl.washington.edu> <20130213033933.GA89757@troutmask.apl.washington.edu> Date: Wed, 13 Feb 2013 04:02:42 +0000 Message-ID: Subject: Re: 7+ days of dogfood From: "b.f." To: Steve Kargl Content-Type: text/plain; charset=ISO-8859-1 Cc: freebsd-current@freebsd.org, Anton Shterenlikht X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: bf1783@gmail.com List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Feb 2013 04:02:43 -0000 On 2/13/13, Steve Kargl wrote: > On Wed, Feb 13, 2013 at 02:15:08AM +0000, b.f. wrote: >> On 2/13/13, Steve Kargl wrote: >> > On Wed, Feb 13, 2013 at 12:18:29AM +0000, b.f. wrote: >> >> ># cat /etc/make.conf|grep FFLAGS >> >> >FFLAGS = -O2 -pipe -march=native -mtune=native >> >> >> >> Please do _not_ assign flags unconditionally in make.conf. >> > >> > FFLAGS is for compiling Fortran. I'm one of the people who >> > has spent years working/patching gfortran. I think I might >> > have a better understanding of what options to use with >> > gfortran than most people. >> > >> >> I know you have, but you are giving advice that is liable to be abused >> by those who are less experienced. The flags you are adding are not >> the problem -- it's the way that you are adding them -- specifically, >> the assignment in the first line of your snippet, if it's applied >> unconditionally. You should either be appending all of them, or >> assigning them conditionally, so that they are sure to be assigned >> only once, or -- preferably -- using another makefile that can't be >> re-read multiple times during a build (ports/Mk/bsd.port.mk >> automatically includes several makefiles that can be used for this >> purpose, if you are building a port). You have been lucky not to trip >> over this: every couple of months for the last several years I have >> had to debug errors reported by users that arise from this problem. It >> is more common with CFLAGS and CXXFLAGS but it can happen with FFLAGS, >> too. > > Try 'find /usr/ports -name Makefile -maxdepth 3 | xargs grep FFLAGS' > Then go read about the options chosen by the various port maintainers. > I specifically set FFLAGS to avoid the questionable options set in > the ports. If -malign-double appears in a port, it should probably > be marked as broken. If a port uses -fdefault-real-8, it should probably > be marked as broken. If a port uses -ffast-math, it may have issues that > are extremely difficult to debug. Okay, so you are doing this advisedly for some specific subset of ports, and have the knowledge to debug problems that may arise -- others don't. Undoubtedly some of these additions are suboptimal or unnecessary -- and I'm sure we'd welcome patches or suggestions to improve them -- but there are also important additions like the rpath flags in $PORTSDIR/Mk/bsd.gcc.mk or mangling and PIC directives. And not all of the additions are in the ports tree makefiles or patchfiles: many software distribution makefiles also make additions that can be clobbered by abusing make.conf. b.