diff options
author | Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> | 2010-03-25 16:42:04 +0100 |
---|---|---|
committer | Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> | 2010-03-25 16:42:04 +0100 |
commit | 02efec110b4e06c249a35eb9aedd14230d4e726d (patch) | |
tree | aa27b6c4a8138590ee362d874d8c1ad45619dada /Makerules | |
parent | abdbaa897b3d7b5b72c8521a38aa84cada242837 (diff) |
pass CFLAGS-dir to CC-m
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Diffstat (limited to 'Makerules')
-rw-r--r-- | Makerules | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -181,6 +181,9 @@ maybe_exec = \ $(cmd_$(1)); \ echo 'cmd_$(call variablify,$@) := $(call dirify,$(cmd_$(call variablify,$1)))' >> $(dir $@).$(notdir $@).dep) +# collect flags of domulti prereqs +#collect_multi_flags = $(CFLAGS-$(notdir $(d))) $(CFLAGS-$(notdir $(patsubst %/,%,$(dir $(d))))) +collect_multi_flags = $(CFLAGS-$(notdir $(patsubst %/,%,$(dir $(d))))) CFLAGS_gen.dep = -MT $@ -MD -MP -MF $(dir $@).$(notdir $@).dep @@ -198,7 +201,7 @@ cmd_compile.S = $(filter-out -std=gnu99, $(cmd_compile.c)) -D__ASSEMBLER__ $(ASF cmd_compile.m = $(cmd_compile.c) -DL_$(patsubst %$(suffix $(notdir $@)),%,$(notdir $@)) cmd_compile.mi= $(cmd_compile.m:-c=-E -dD $(EXTRA_CPPFLAGS)) -cmd_compile-m = $(CC) $^ -c -o $@ $(CFLAGS) $(CFLAGS-$(suffix $@)) $(CFLAGS-$(notdir $(@D))) $(CFLAGS-$(notdir $@)) +cmd_compile-m = $(CC) $^ -c -o $@ $(CFLAGS) $(CFLAGS-$(suffix $@)) $(CFLAGS-$(notdir $(@D))) $(CFLAGS-$(notdir $@)) $(sort $(foreach d,$(^:$(top_srcdir)=),$(collect_multi_flags))) cmd_strip = $(STRIPTOOL) $(STRIP_FLAGS) $^ cmd_t_strip = $(STRIPTOOL) $(STRIP_FLAGS) $@ cmd_ar = $(AR) $(ARFLAGS) $@ $^ |