powerpc: convert makefiles to Kbuild style
authorMasahiro Yamada <yamada.m@jp.panasonic.com>
Thu, 17 Oct 2013 08:35:04 +0000 (17:35 +0900)
committerTom Rini <trini@ti.com>
Thu, 31 Oct 2013 17:26:44 +0000 (13:26 -0400)
commit06c14117c44e4b93be0430740524d4e2ef2557c0
tree953310770487931e0adcd07a3a34297d5ef93279
parent7cf40824bea10590cf2bb14ecfaa4c14ee907017
powerpc: convert makefiles to Kbuild style

Note:
arch/powerpc/cpu/mpc8260/Makefile is originally like follows:

    ---<snip>---
    START   = start.o kgdb.o
    COBJS   = traps.o serial_smc.o serial_scc.o cpu.o cpu_init.o speed.o \
    ---<snip>---
    COBJS-$(CONFIG_ETHER_ON_SCC) = ether_scc.o
    ---<snip>---
    $(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 <yamada.m@jp.panasonic.com>
Cc: Wolfgang Denk <wd@denx.de>
Cc: Stefan Roese <sr@denx.de>
14 files changed:
arch/powerpc/cpu/74xx_7xx/Makefile
arch/powerpc/cpu/mpc512x/Makefile
arch/powerpc/cpu/mpc5xx/Makefile
arch/powerpc/cpu/mpc5xxx/Makefile
arch/powerpc/cpu/mpc824x/Makefile
arch/powerpc/cpu/mpc8260/Makefile
arch/powerpc/cpu/mpc83xx/Makefile
arch/powerpc/cpu/mpc85xx/Makefile
arch/powerpc/cpu/mpc86xx/Makefile
arch/powerpc/cpu/mpc8xx/Makefile
arch/powerpc/cpu/mpc8xxx/Makefile
arch/powerpc/cpu/mpc8xxx/ddr/Makefile
arch/powerpc/cpu/ppc4xx/Makefile
arch/powerpc/lib/Makefile