From mi@privatelabs.com  Thu May 18 09:38:09 2000
Return-Path: <mi@privatelabs.com>
Received: from privatecube.privatelabs.com (privatecube.privatelabs.com [198.143.31.30])
	by hub.freebsd.org (Postfix) with ESMTP id C73EB37BA1D
	for <FreeBSD-gnats-submit@freebsd.org>; Thu, 18 May 2000 09:38:07 -0700 (PDT)
	(envelope-from mi@privatelabs.com)
Received: from misha.privatelabs.com (root@misha.privatelabs.com [198.143.31.6])
	by privatecube.privatelabs.com (8.9.2/8.9.2) with ESMTP id LAA26638
	for <FreeBSD-gnats-submit@freebsd.org>; Thu, 18 May 2000 11:36:52 -0400 (EDT)
Received: (from root@localhost)
	by misha.privatelabs.com (8.9.3/8.9.3) id MAA04046;
	Thu, 18 May 2000 12:37:43 -0400 (EDT)
	(envelope-from mi)
Message-Id: <200005181637.MAA04046@misha.privatelabs.com>
Date: Thu, 18 May 2000 12:37:43 -0400 (EDT)
From: root@misha.privatelabs.com
Sender: mi@privatelabs.com
Reply-To: mi@aldan.algebra.com
To: FreeBSD-gnats-submit@freebsd.org
Subject: sysutils/syslog-ng ignores CFLAGS
X-Send-Pr-Version: 3.2

>Number:         18661
>Category:       ports
>Synopsis:       sysutils/syslog-ng ignores CFLAGS
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    will
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Thu May 18 09:40:00 PDT 2000
>Closed-Date:    Sun May 21 17:24:11 PDT 2000
>Last-Modified:  Sun May 21 17:24:42 PDT 2000
>Originator:     Mikhail Teterin
>Release:        FreeBSD 4.0-STABLE i386
>Organization:
Virtual Estates, Inc.
>Environment:

>Description:

	The  software's  configure  script detects  the  desired
	CFLAGS properly, but then overrides  them. This is a bug
	in the original configure script,  which can be fixed by
	the included patch. This patch should be placed into the
	port's patches/patch-ab

>How-To-Repeat:

	Try building and  see, that the source  is compiled with
	``-O2 -Wall''.

>Fix:

	Put  the  following   into  patches/patch-ab.  The  same
	problem exists in the devel/libol port, and can be fixed
	by  a similar  patch  or  by what  I  submitted with  an
	earlier ports/18659.

--- configure	Wed Apr 19 12:46:10 2000
+++ configure	Thu May 18 12:22:27 2000
@@ -2638,3 +2638,3 @@
 else
-	CFLAGS="-O2 -Wall $LIBOL_CFLAGS -D_GNU_SOURCE"
+	CFLAGS="${CFLAGS} -Wall $LIBOL_CFLAGS -D_GNU_SOURCE"
 	YFLAGS="-d"

>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-ports->will 
Responsible-Changed-By: will 
Responsible-Changed-When: Thu May 18 17:21:22 PDT 2000 
Responsible-Changed-Why:  
I'll handle this one. 

From: Will Andrews <andrews@technologist.com>
To: mi@aldan.algebra.com
Cc: FreeBSD-gnats-submit@FreeBSD.ORG, vince@blue-box.net
Subject: Re: ports/18661: sysutils/syslog-ng ignores CFLAGS
Date: Thu, 18 May 2000 20:20:56 -0400

 On Thu, May 18, 2000 at 12:37:43PM -0400, root@misha.privatelabs.com wrote:
 > >Fix:
 > 
 > 	Put  the  following   into  patches/patch-ab.  The  same
 > 	problem exists in the devel/libol port, and can be fixed
 > 	by  a similar  patch  or  by what  I  submitted with  an
 > 	earlier ports/18659.
 > 
 > --- configure	Wed Apr 19 12:46:10 2000
 > +++ configure	Thu May 18 12:22:27 2000
 > @@ -2638,3 +2638,3 @@
 >  else
 > -	CFLAGS="-O2 -Wall $LIBOL_CFLAGS -D_GNU_SOURCE"
 > +	CFLAGS="${CFLAGS} -Wall $LIBOL_CFLAGS -D_GNU_SOURCE"
 >  	YFLAGS="-d"
 
 Maintainer, is this patch approved?  It is ports policy to enforce
 CFLAGS in ports wherever possible.  However, in case there's a good
 reason why it HAS to be -O2, speak up now or forever hold your peace.
 
 (Geez, I sound like a minister)
 -- 
 Will Andrews <andrews@technologist.com>
 GCS/E/S @d- s+:+>+:- a--->+++ C++ UB++++ P+ L- E--- W+++ !N !o ?K w---
 ?O M+ V-- PS+ PE++ Y+ PGP+>+++ t++ 5 X++ R+ tv+ b++>++++ DI+++ D+ 
 G++>+++ e->++++ h! r-->+++ y?
 

From: Will Andrews <andrews@technologist.com>
To: mi@aldan.algebra.com, vince@blue-box.net
Cc: FreeBSD-gnats-submit@FreeBSD.org
Subject: Re: ports/18661: sysutils/syslog-ng ignores CFLAGS
Date: Thu, 18 May 2000 20:36:39 -0400

 On Thu, May 18, 2000 at 05:30:01PM -0700, Will Andrews wrote:
 > +	CFLAGS="${CFLAGS} -Wall $LIBOL_CFLAGS -D_GNU_SOURCE"
 
 Actually, doesn't this sort of thing result in make(1) spewing something
 like "recursive variable CFLAGS" or similar?  This may not be the best
 way to implement enforced CFLAGS.  You probably should have something
 like ${PCFLAGS} here instead, and define PCFLAGS= ${CFLAGS} in the port
 Makefile.
 
 -- 
 Will Andrews <andrews@technologist.com>
 GCS/E/S @d- s+:+>+:- a--->+++ C++ UB++++ P+ L- E--- W+++ !N !o ?K w---
 ?O M+ V-- PS+ PE++ Y+ PGP+>+++ t++ 5 X++ R+ tv+ b++>++++ DI+++ D+ 
 G++>+++ e->++++ h! r-->+++ y?
 

From: Vince Valenti <vince@bendnet.com>
To: Will Andrews <andrews@technologist.com>
Cc: mi@aldan.algebra.com, FreeBSD-gnats-submit@FreeBSD.org
Subject: Re: ports/18661: sysutils/syslog-ng ignores CFLAGS
Date: Thu, 18 May 2000 21:39:40 -0700 (PDT)

 On Thu, 18 May 2000, Will Andrews wrote:
 
 > On Thu, May 18, 2000 at 05:30:01PM -0700, Will Andrews wrote:
 > > +	CFLAGS="${CFLAGS} -Wall $LIBOL_CFLAGS -D_GNU_SOURCE"
 > 
 > Actually, doesn't this sort of thing result in make(1) spewing
 > something like "recursive variable CFLAGS" or similar?  This may not
 > be the best way to implement enforced CFLAGS.  You probably should
 > have something like ${PCFLAGS} here instead, and define PCFLAGS=
 > ${CFLAGS} in the port Makefile.
 
 It seemed to work when I ran the suggested patch...  I'd say go ahead and
 commit it.  If it would be better to have a PCFLAGS variable, I can whip
 up a patch for that if you'd like.
 
 Thanks,
 
 -- 
 Vince Valenti
 Network Services
 BendNet
 
 

From: mi@privatelabs.com
To: Will Andrews <andrews@technologist.com>
Cc: mi@aldan.algebra.com, vince@blue-box.net,
	FreeBSD-gnats-submit@FreeBSD.org
Subject: Re: ports/18661: sysutils/syslog-ng ignores CFLAGS
Date: Fri, 19 May 2000 11:33:47 -0400 (EDT)

 On 18 May, Will Andrews wrote:
 = On Thu, May 18, 2000 at 05:30:01PM -0700, Will Andrews wrote:
 = > +	CFLAGS="${CFLAGS} -Wall $LIBOL_CFLAGS -D_GNU_SOURCE"
 = 
 = Actually,  doesn't  this  sort  of thing  result  in  make(1)  spewing
 = something like "recursive variable CFLAGS" or similar? This may not be
 = the best  way to implement  enforced CFLAGS. You probably  should have
 = something like ${PCFLAGS} here  instead, and define PCFLAGS= ${CFLAGS}
 = in the port Makefile.
 
 No. The whole  replacement takes place in the shell  -- I'm patching the
 configure  script, not  the  Makefile.  Is not  it  easier  to test  for
 yourself :(?
 
 	-mi
 
 
 
State-Changed-From-To: open->closed 
State-Changed-By: will 
State-Changed-When: Sun May 21 17:24:11 PDT 2000 
State-Changed-Why:  
Committed, thanks! 
>Unformatted:
