From 71f84ef0730e992f50bd82d17a003daafd149cad Mon Sep 17 00:00:00 2001 From: Masahiro Yamada Date: Thu, 17 Oct 2013 17:34:53 +0900 Subject: ARM: imx-common: convert makefiles to Kbuild style Multiple targets are included in arch/arm/imx-common/Makefile In order to refactor it, we need to tweak Makefile and spl/Makefile. Signed-off-by: Masahiro Yamada --- arch/arm/imx-common/Makefile | 35 ++++++----------------------------- 1 file changed, 6 insertions(+), 29 deletions(-) (limited to 'arch/arm/imx-common') diff --git a/arch/arm/imx-common/Makefile b/arch/arm/imx-common/Makefile index 6c78dd9..2c80441 100644 --- a/arch/arm/imx-common/Makefile +++ b/arch/arm/imx-common/Makefile @@ -7,31 +7,18 @@ # SPDX-License-Identifier: GPL-2.0+ # -include $(TOPDIR)/config.mk - -LIB = $(obj)libimx-common.o - ifeq ($(SOC),$(filter $(SOC),mx25 mx35 mx5 mx6 vf610)) -COBJS-y = iomux-v3.o +obj-y = iomux-v3.o endif ifeq ($(SOC),$(filter $(SOC),mx5 mx6)) -COBJS-y += timer.o cpu.o speed.o -COBJS-$(CONFIG_SYS_I2C_MXC) += i2c-mxv7.o +obj-y += timer.o cpu.o speed.o +obj-$(CONFIG_SYS_I2C_MXC) += i2c-mxv7.o endif ifeq ($(SOC),$(filter $(SOC),mx6 mxs)) -COBJS-y += misc.o +obj-y += misc.o endif -COBJS-$(CONFIG_CMD_BMODE) += cmd_bmode.o -COBJS-$(CONFIG_CMD_HDMIDETECT) += cmd_hdmidet.o -COBJS := $(sort $(COBJS-y)) - -SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c) -OBJS := $(addprefix $(obj),$(SOBJS) $(COBJS)) - -all: $(obj).depend $(LIB) - -$(LIB): $(OBJS) - $(call cmd_link_o_target, $(OBJS)) +obj-$(CONFIG_CMD_BMODE) += cmd_bmode.o +obj-$(CONFIG_CMD_HDMIDETECT) += cmd_hdmidet.o $(OBJTREE)/$(patsubst "%",%,$(CONFIG_IMX_CONFIG)).cfgtmp: $(OBJTREE)/%.cfgtmp : $(SRCTREE)/% mkdir -p $(dir $@) @@ -67,13 +54,3 @@ $(OBJTREE)/u-boot-with-nand-spl.imx: $(OBJTREE)/SPL $(OBJTREE)/u-boot.bin $(OBJTREE)/u-boot.uim cat $(OBJTREE)/spl/u-boot-nand-spl-pad.imx $(OBJTREE)/u-boot.uim > $@ rm $(OBJTREE)/spl/u-boot-nand-spl-pad.imx $(OBJTREE)/u-boot.uim - - -######################################################################### - -# defines $(obj).depend target -include $(SRCTREE)/rules.mk - -sinclude $(obj).depend - -######################################################################### -- cgit v1.1