From owner-freebsd-ports@FreeBSD.ORG Thu Jan 9 09:48:00 2014 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 8B3BA28C for ; Thu, 9 Jan 2014 09:48:00 +0000 (UTC) Received: from mail-ob0-x22b.google.com (mail-ob0-x22b.google.com [IPv6:2607:f8b0:4003:c01::22b]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 342DC10CA for ; Thu, 9 Jan 2014 09:48:00 +0000 (UTC) Received: by mail-ob0-f171.google.com with SMTP id wo20so1038328obc.2 for ; Thu, 09 Jan 2014 01:47:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=grimstveit.no; s=google; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; bh=WBN3K/dsfQ3ptVcbUJsrnafnr4U1NJ5sC0x//+6CbKU=; b=gSSW9o/MUJMQPYHPDtLoJ7vv5rtj1GUlN5z+P5o1ae4qsXV25s1kUYnGSKmosTQ0CU TxlV+QCu7+AiuxIjSbmT2WpR5h6naQTn8m4j7h/OnnVsyLxbSuahjxSH0sZCIL0BKG3F hQ2c3f6mFtsSjkTO2CC/Wmhs0NevqWmr/vjdc= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-type; bh=WBN3K/dsfQ3ptVcbUJsrnafnr4U1NJ5sC0x//+6CbKU=; b=jKuNthggBoyQ5Yijzq4To5cI/kN9qX+t9SNBLqau/q1iu5lGpF8mnYBO8j4HHfVKx6 Jqts+SDdY/kEWH2HcFD7aRRVeQQ10CW60J0zuBQRtNLY0DfT4jo7PkECJ5C70vL8shFR L4+IbIHf0ESnJVPgMg7f8kcFbgpLnAjTTulvyiJEMS0murNqFKo2LhyIRPerWe/q2mZc d0zOxxATLam91p5FHRZtHr6/4Lsj0tMxM0wvD+2R09jmZ+/J0weHxH1X+SKe59iAPk+1 e7fkpZtnyyh2kfc32AjbsOtGVT1qfZQl4Xqzi3Of/IYlGhAtG+0oANxGzsDRUYwWBY0h by7w== X-Gm-Message-State: ALoCoQmGVBK10Giz0JFZFWosSS1KP7vlR+WMQMFCKnA7J+4+0zoK/uvlYTwVgq/UApWLwq+koy3N X-Received: by 10.60.92.137 with SMTP id cm9mr1559605oeb.38.1389260879383; Thu, 09 Jan 2014 01:47:59 -0800 (PST) MIME-Version: 1.0 Received: by 10.76.184.199 with HTTP; Thu, 9 Jan 2014 01:47:39 -0800 (PST) In-Reply-To: <52BE4749.4040703@FreeBSD.org> References: <52BE4749.4040703@FreeBSD.org> From: Jakob Breivik Grimstveit Date: Thu, 9 Jan 2014 10:47:39 +0100 Message-ID: Subject: Re: postfix-current spewing out warnings while building To: koobs@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.17 Cc: FreeBSD Ports mailing list , sahil@freebsd.org X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 09 Jan 2014 09:48:00 -0000 Thank you for the explanatory reply. Much appreciated. I've tried, however, patching mail/postfix (not lang/postfix), but I get the following erroneous output: # pwd /usr/ports/mail/postfix # patch < postfix-also-respect-default-warnings-too.diff Hmm... Looks like a unified diff to me... The text leading up to this was: -------------------------- |Index: Makefile |=================================================================== |--- Makefile (revision 337172) |+++ Makefile (working copy) -------------------------- Patching file Makefile using Plan A... patch: **** malformed patch at line 7: MAKEFILEFLAGS+= CC="${CC}" OPT="${CFLAGS}" FYI. I assume you and maintainer are much better at this than I am :-). -- Vyrdsamt, Jakob Breivik Grimstveit | +47 4829 8152 http://grimstveit.no/jakob On Sat, Dec 28, 2013 at 4:36 AM, Kubilay Kocak wrote: > On 27/12/2013 6:59 PM, Jakob Breivik Grimstveit wrote: > > mail/postfix-current behaves somewhat strange while building, is it > > anything I should correct? > > > > > > $ sudo make clean > > make: "/usr/ports/mail/postfix-current/Makefile" line 92: warning: > Couldn't > > read shell's output for "/usr/bin/grep -m 1 '^purgestat' > > /etc/mail/mailer.conf || true" > > make[1]: "/usr/ports/mail/postfix-current/Makefile" line 92: warning: > > Couldn't read shell's output for "/usr/bin/grep -m 1 '^purgestat' > > /etc/mail/mailer.conf || true" > > ===> Cleaning for postfix-current-base-2.11.20131001,4 > > make[1]: "/usr/ports/mail/postfix-current/Makefile" line 92: warning: > > Couldn't read shell's output for "/usr/bin/grep -m 1 '^purgestat' > > /etc/mail/mailer.conf || true" > > > > [...] > > > > And while building, I get a bunch (probably thousands) of these: > > > > duplex_pipe.c:8:1: warning: '/*' within block comment [-Wcomment] > > /* > > ^ > > duplex_pipe.c:9:1: warning: '/*' within block comment [-Wcomment] > > /* int duplex_pipe(fds) > > ^ > > duplex_pipe.c:10:1: warning: '/*' within block comment [-Wcomment] > > /* int *fds; > > ^ > > > > [...] > > > > ../../include/argv.h:6:1: warning: '/*' within block comment [-Wcomment] > > /* argv 3h > > ^ > > ../../include/argv.h:7:1: warning: '/*' within block comment [-Wcomment] > > /* SUMMARY > > ^ > > ../../include/argv.h:8:1: warning: '/*' within block comment [-Wcomment] > > /* string array utilities > > ^ > > ../../include/argv.h:9:1: warning: '/*' within block comment [-Wcomment] > > /* SYNOPSIS > > ^ > > > > Thank you in advance. > > > > Hi Jakob, > > These comment warnings have been observable for as long as I can > remember, though only with postfix ports (not upstream) when also built > with clang. > > This is caused by the override of CC and CCARGS, which clobbers the > warnings postfix configures by default. Another instance of these > symptoms, albeit with a slightly different root cause can be seen here: > > http://marc.info/?l=postfix-users&m=134260003817238&w=2 > > The reason behind the override is a policy in the porters handbook that > recommends respecting user-supplied CC, CXX and CFLAGS, which the > postfix ports follow: > > > http://www.au.freebsd.org/doc/en_US.ISO8859-1/books/porters-handbook/book.html#dads-cc > > > http://www.au.freebsd.org/doc/en_US.ISO8859-1/books/porters-handbook/book.html#dads-cflags > > While the recommendations above are well-intentioned and grounded > (respect user choice & consistent builds), this is one example of where > doing so is at least a POLA violation, but ultimately harmless. > > At worst, for other software in the ports tree where upstream authors > customise flags for very good reasons, the results could be functionally > pathological. This is fortunately not the case here, but worth us > considering more broadly. > > Attached is a patch (to lang/postfix) which restores the default warning > flags while continuing to respect user-supplied flags. This can likely > be applied to all postfix ports. Maintainer is CC'd. > > I've tested it quickly here with the expected results, if you could do > the same and let us know how it goes, that would be great. > > Thanks :) > > -- > koobs > >