On Tue, May 25, 2010 at 5:06 PM, Paolo Bonzini <bonz...@gnu.org> wrote:
> On Tue, May 25, 2010 at 16:59, Andreas Schwab <sch...@redhat.com> wrote:
>> Steven Bosscher <stevenb....@gmail.com> writes:
>>
>>> So I guess this plan of mine is not going to work...
>>> Other ideas?
>>
>> Add $(CFLAGS-$(@F)) to the .c.o rule
>
> Actually $@ is fine, since you want cp/tree.o to have different flags
> from tree.o.

Well, it looks like I do need something like @F because I now only get
the define on files in gcc/. Any file with a / in the full name $@
does not get a file specific CFLAGS.


>> and define CFLAGS-foo for each foo
>> in $(ALL_HOST_FRONTEND_OBJS).  Though the latter is a bit tricky if you
>> want to do it automatically.
>
> That would be something like
>
> $(foreach file,$(ALL_HOST_FRONTEND_OBJS),$(eval CFLAGS-$(file) += ...))

Same here.

Maybe I should sed away the slashes? Or is there a better way?

Ciao!
Steven

Reply via email to