This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: user hostile gobbledygook in top level Makefile
- To: "Zack Weinberg" <zackw at stanford dot edu>
- Subject: Re: user hostile gobbledygook in top level Makefile
- From: Alexandre Oliva <aoliva at redhat dot com>
- Date: 20 Nov 2000 02:46:17 -0200
- Cc: gcc at gcc dot gnu dot org
- Organization: GCC Team, Red Hat
- References: <20001119144824.F17712@wolery.stanford.edu>
On Nov 19, 2000, "Zack Weinberg" <zackw@stanford.edu> wrote:
> So I'm trying to figure out why I can't override BOOT_CFLAGS on the
> command line from the top level
You can. Or, at least, you're supposed to be able to do it.
> I see this in the top Makefile.in:
> "`echo 'BOOT_CFLAGS=$(BOOT_CFLAGS)' | sed -e s/.*=$$/XFOO=/`"
> Now, unless I am sorely confused, the effect of those echo | sed
> commands is to convert "BOOT_CFLAGS=-fwhatever" into
> "XFOO=-fwhatever", which means the subdir makefile won't see it.
You're sorely confused :-)
Note the `$$'. The purpose seems to be to replace `BOOT_CFLAGS=' with
`XFOO=', as long as $(BOOT_CFLAGS) is empty. I.e., if you set
BOOT_CFLAGS to non-empty, it will be passed down, but if you don't
override it (note that it's not set in the top-level Makefile), you
don't get the definition in the sub-directory overridden by the
non-definition in the top level.
--
Alexandre Oliva Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer aoliva@{cygnus.com, redhat.com}
CS PhD student at IC-Unicamp oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist *Please* write to mailing lists, not to me