From 06c14117c44e4b93be0430740524d4e2ef2557c0 Mon Sep 17 00:00:00 2001 From: Masahiro Yamada Date: Thu, 17 Oct 2013 17:35:04 +0900 Subject: powerpc: convert makefiles to Kbuild style Note: arch/powerpc/cpu/mpc8260/Makefile is originally like follows: ------ START = start.o kgdb.o COBJS = traps.o serial_smc.o serial_scc.o cpu.o cpu_init.o speed.o \ ------ COBJS-$(CONFIG_ETHER_ON_SCC) = ether_scc.o ------ $(LIB): $(OBJS) $(call cmd_link_o_target, $(OBJS) $(obj)kgdb.o) The link rule `$(call cmd_link_o_target, $(OBJS) $(obj)kgdb.o)' is weird. kbdg.o is not included in $(OBJS) but linked into $(LIB) and $(LIB) is not dependent on kgdb.o. (Broken dependency tracking) So, START = start.o kgdb.o shoud have been START = start.o SOBJS = kgdb.o That is why this commit adds kgdb.o to obj-y, not to extra-y. Signed-off-by: Masahiro Yamada Cc: Wolfgang Denk Cc: Stefan Roese --- arch/powerpc/cpu/74xx_7xx/Makefile | 28 +++------------------------- 1 file changed, 3 insertions(+), 25 deletions(-) (limited to 'arch/powerpc/cpu/74xx_7xx') diff --git a/arch/powerpc/cpu/74xx_7xx/Makefile b/arch/powerpc/cpu/74xx_7xx/Makefile index de9b4a72cd..f31fe756e3 100644 --- a/arch/powerpc/cpu/74xx_7xx/Makefile +++ b/arch/powerpc/cpu/74xx_7xx/Makefile @@ -8,28 +8,6 @@ # SPDX-License-Identifier: GPL-2.0+ # -include $(TOPDIR)/config.mk - -LIB = $(obj)lib$(CPU).o - -START = start.o -SOBJS = cache.o kgdb.o io.o -COBJS = traps.o cpu.o cpu_init.o speed.o interrupts.o - -SRCS := $(START:.o=.S) $(SOBJS:.o=.S) $(COBJS:.o=.c) -OBJS := $(addprefix $(obj),$(SOBJS) $(COBJS)) -START := $(addprefix $(obj),$(START)) - -all: $(obj).depend $(START) $(LIB) - -$(LIB): $(OBJS) - $(call cmd_link_o_target, $(OBJS)) - -######################################################################### - -# defines $(obj).depend target -include $(SRCTREE)/rules.mk - -sinclude $(obj).depend - -######################################################################### +extra-y = start.o +obj-y = cache.o kgdb.o io.o +obj-y += traps.o cpu.o cpu_init.o speed.o interrupts.o -- cgit