blob: 3168e979f22202f2e7b393fb9014a226a3c10589 [file] [log] [blame]
Nobuhiro Iwamatsu4fb44e22012-06-13 16:29:47 +09001#
2# (C) Copyright 2000-2006
3# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
4#
Wolfgang Denk1a459662013-07-08 09:37:19 +02005# SPDX-License-Identifier: GPL-2.0+
Nobuhiro Iwamatsu4fb44e22012-06-13 16:29:47 +09006#
7
8include $(TOPDIR)/config.mk
9
10LIB = $(obj)lib$(SOC).o
11
Nobuhiro Iwamatsu1cdf2482012-08-19 04:40:05 +000012SOBJS = lowlevel_init.o
13COBJS-y += cpu_info.o
Nobuhiro Iwamatsu2d610842012-08-06 07:26:09 +090014COBJS-y += emac.o
Nobuhiro Iwamatsu4fb44e22012-06-13 16:29:47 +090015
Nobuhiro Iwamatsu1cdf2482012-08-19 04:40:05 +000016COBJS-$(CONFIG_DISPLAY_BOARDINFO) += board.o
Nobuhiro Iwamatsu2c541df2012-08-03 14:21:05 +090017COBJS-$(CONFIG_GLOBAL_TIMER) += timer.o
Nobuhiro Iwamatsucfa291b2012-07-20 13:06:54 +090018COBJS-$(CONFIG_R8A7740) += cpu_info-r8a7740.o
19COBJS-$(CONFIG_R8A7740) += pfc-r8a7740.o
Nobuhiro Iwamatsu1cdf2482012-08-19 04:40:05 +000020COBJS-$(CONFIG_SH73A0) += cpu_info-sh73a0.o
Nobuhiro Iwamatsub045a232012-07-20 09:29:19 +090021COBJS-$(CONFIG_SH73A0) += pfc-sh73a0.o
Nobuhiro Iwamatsu35729c62012-10-02 16:40:39 +000022COBJS_LN-$(CONFIG_TMU_TIMER) += sh_timer.o
Nobuhiro Iwamatsu1cdf2482012-08-19 04:40:05 +000023
24COBJS := $(COBJS-y)
25SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
Nobuhiro Iwamatsu35729c62012-10-02 16:40:39 +000026SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c) $(addprefix $(obj),$(COBJS_LN-y:.o=.c))
27OBJS := $(addprefix $(obj),$(SOBJS) $(COBJS) $(COBJS_LN-y))
Nobuhiro Iwamatsu1cdf2482012-08-19 04:40:05 +000028SOBJS := $(addprefix $(obj),$(SOBJS))
Nobuhiro Iwamatsu4fb44e22012-06-13 16:29:47 +090029START := $(addprefix $(obj),$(START))
30
31all: $(obj).depend $(LIB)
32
33$(LIB): $(OBJS)
34 $(call cmd_link_o_target, $(OBJS))
35
Nobuhiro Iwamatsu35729c62012-10-02 16:40:39 +000036# from arch/sh/lib/ directory
37$(obj)sh_timer.c:
38 @rm -f $(obj)sh_timer.c
39 ln -s $(SRCTREE)/arch/sh/lib/time.c $(obj)sh_timer.c
40
Nobuhiro Iwamatsu4fb44e22012-06-13 16:29:47 +090041#########################################################################
42
43# defines $(obj).depend target
44include $(SRCTREE)/rules.mk
45
46sinclude $(obj).depend
47
48#########################################################################
49