[U-Boot] [PATCH 2/2] tools: Use override when changing CC, CFLAGS, etc.

Scott Wood scottwood at freescale.com
Tue Oct 20 23:53:58 CEST 2009


Mike Frysinger wrote:
> On Monday 19 October 2009 17:24:35 Scott Wood wrote:
>> If the user has specified a CC or similar on the command line, that is the
>> cross compiler, not the host compiler.  Override is needed to keep these
>> assignments from being ignored in that case.
> 
> then again, if we didnt mix host and target variable names, this wouldnt be a 
> problem.  in a sane world, all of the host stuff would be HOSTXX (or BUILDXX).

I was looking at making static pattern rules to divert host objects to a 
host rule, with separate object lists for files that want pedantic and 
non-pedantic (leaving the current set of individual file rules would 
cause conflicts).

It seems that nothing in tools/Makefile is using -pedantic or any of the 
other HOSTCFLAGS set in tools/Makefile; HOSTCFLAGS is getting 
overwritten by config.mk.  It looks like maybe this was introduced when 
HOST_CFLAGS was changed to HOSTCFLAGS.

Any thoughts on how to untangle things?  What flags to we really want to 
use here?  Given the number of files that have been exempted, do we 
still want to keep the -pedantic stuff around?

-Scott


More information about the U-Boot mailing list