Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 13 Feb 2004 12:19:09 -0500
From:      Chuck Swiger <cswiger@mac.com>
To:        Paul Seniura <pdseniura@techie.com>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: need help on CFLAGS in /etc/make.conf please
Message-ID:  <402D070D.90506@mac.com>
In-Reply-To: <20040213035608.3AA11A38EA@scifi.homeip.net>
References:  <20040213001703.616C75C3B@techpc04.okladot.state.ok.us> <20040213011324.GA55948@xor.obsecurity.org> <20040213035608.3AA11A38EA@scifi.homeip.net>

next in thread | previous in thread | raw e-mail | index | archive | help
Hi, Paul--

There is little point to crossposting between -questions and -hackers; 
dropping the latter.  Actually, <ports@freebsd.org> is probably the most 
appropriate place...

Paul Seniura wrote:
> My question for this discussion is specifically how to prevent
> overriding a port's own setting for that parm, and to provide a
> default setting -O[1] when the port does not set it at all?

Well-behaved ports respect CFLAGS, meaning that you can define that variable 
in /etc/make.conf (or on the command line when you invoke make), and the port 
should use that value when building the software.

If you tell us which port is broken, someone will fix it.  For example, one of 
the ports I maintain the author explicitly sets -O2, but the port Makefile 
patches that via:

post-patch:
         ${REINPLACE_CMD} -e 's/-O2//' ${WRKSRC}/Makefile

-- 
-Chuck



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?402D070D.90506>