summaryrefslogtreecommitdiffstats
path: root/scripts/Makefile.build
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/Makefile.build')
-rw-r--r--scripts/Makefile.build33
1 files changed, 7 insertions, 26 deletions
diff --git a/scripts/Makefile.build b/scripts/Makefile.build
index f575a07fdf..ed2bb28c55 100644
--- a/scripts/Makefile.build
+++ b/scripts/Makefile.build
@@ -118,24 +118,17 @@ cmd_cc_i_c = $(CPP) $(c_flags) -o $@ $<
quiet_cmd_cc_o_c = CC $(quiet_modtag) $@
cmd_cc_o_c = $(CC) $(c_flags) -c -o $@ $<
-quiet_cmd_pbl_cc_o_c = PBLCC $@
- cmd_pbl_cc_o_c = $(CC) -D__PBL__ $(c_flags) $(PBL_CPPFLAGS) -c -o $@ $<
define rule_cc_o_c
$(call cmd,checksrc)
$(call cmd_and_fixdep,cc_o_c)
endef
-define rule_pbl_cc_o_c
- $(call cmd,checksrc)
- $(call cmd_and_fixdep,pbl_cc_o_c)
-endef
-
# Built-in and composite module parts
%.pbl.o: %.c FORCE
$(call cmd,force_checksrc)
- $(call if_changed_rule,pbl_cc_o_c)
+ $(call if_changed_rule,cc_o_c)
%.o: %.c FORCE
$(call cmd,force_checksrc)
@@ -168,11 +161,8 @@ cmd_as_s_S = $(CPP) $(a_flags) -o $@ $<
quiet_cmd_as_o_S = AS $(quiet_modtag) $@
cmd_as_o_S = $(CC) $(a_flags) -c -o $@ $<
-quiet_cmd_pbl_as_o_S = PBLAS $@
-cmd_pbl_as_o_S = $(CC) -D__PBL__ $(a_flags) $(PBL_CPPFLAGS) -c -o $@ $<
-
%.pbl.o: %.S FORCE
- $(call if_changed_dep,pbl_as_o_S)
+ $(call if_changed_dep,as_o_S)
%.o: %.S FORCE
$(call if_changed_dep,as_o_S)
@@ -198,31 +188,22 @@ $(sort $(subdir-obj-y)): $(subdir-ym) ;
#
# Rule to compile a set of .o files into one .o file
#
-ifdef builtin-target
-quiet_cmd_link_o_target = LD $@
+
# If the list of objects to link is empty, just create an empty built-in.o
-cmd_link_o_target = $(if $(strip $(obj-y)),\
- $(LD) $(ld_flags) -r -o $@ $(filter $(obj-y), $^),\
+quiet_cmd_link_o_target = LD $(quiet_modtag) $@
+cmd_link_o_target = $(if $(strip $(real-prereqs)),\
+ $(LD) $(ld_flags) -r -o $@ $(real-prereqs),\
rm -f $@; $(AR) rcs $@)
$(builtin-target): $(obj-y) FORCE
$(call if_changed,link_o_target)
targets += $(builtin-target)
-endif # builtin-target
-
-ifdef pbl-target
-quiet_cmd_pbl_link_o_target = PBLLD $@
-# If the list of objects to link is empty, just create an empty built-in-pbl.o
-cmd_pbl_link_o_target = $(if $(strip $(pbl-y)),\
- $(LD) $(ld_flags) -r -o $@ $(filter $(pbl-y), $^),\
- rm -f $@; $(AR) rcs $@)
$(pbl-target): $(pbl-y) FORCE
- $(call if_changed,pbl_link_o_target)
+ $(call if_changed,link_o_target)
targets += $(pbl-target)
-endif # pbl-target
#
# Rule to compile a set of .o files into one .a file