On Tuesday, June 28, 2011 02:54:03 Michał Górny wrote:
> On Tue, 28 Jun 2011 10:16:06 +0400 Peter Volkov wrote:
> > But still our documentation explicitly suggests ':' for CFLAGS cases
> > and example allows bash substitution.
> > 
> > http://devmanual.gentoo.org/ebuild-writing/functions/src_compile/building
> > /index.html see example in "Fixing Compiler Usage" section and text
> > below:
> > sed -i -e "s:cc -O2:$(tc-getCC) ${CFLAGS} ${LDFLAGS}:" build.sh
> > 
> > Are there any objections to suggest '|' for CFLAGS, LDFLAGS (see
> > attachment)?
> 
> I think that also a good idea may be to provide an Makefile example,
> showing that often sed is unnecessary, and it's enough to do things
> like:
> 
> emake CC="$(tc-getCC)" CFLAGS="${CFLAGS}"...

this is easily dangerous when it comes to packages (and many do) that append 
in the Makefile.  specifying on the command line blocks those while passing 
via env works fine.  i'm not sure it's appropriate to provide as an example.
-mike

Attachment: signature.asc
Description: This is a digitally signed message part.

Reply via email to