Chander Kashyap | e21185b | 2011-05-24 20:02:56 +0000 | [diff] [blame] | 1 | # |
| 2 | # Copyright (C) 2011 Samsung Electronics |
| 3 | # |
Wolfgang Denk | 1a45966 | 2013-07-08 09:37:19 +0200 | [diff] [blame^] | 4 | # SPDX-License-Identifier: GPL-2.0+ |
Chander Kashyap | e21185b | 2011-05-24 20:02:56 +0000 | [diff] [blame] | 5 | # |
| 6 | |
| 7 | include $(TOPDIR)/config.mk |
| 8 | |
| 9 | LIB = $(obj)lib$(BOARD).o |
| 10 | |
Chander Kashyap | 5187d8d | 2011-09-20 21:25:03 +0000 | [diff] [blame] | 11 | ifndef CONFIG_SPL_BUILD |
Chander Kashyap | e21185b | 2011-05-24 20:02:56 +0000 | [diff] [blame] | 12 | COBJS += smdkv310.o |
Chander Kashyap | 5187d8d | 2011-09-20 21:25:03 +0000 | [diff] [blame] | 13 | endif |
| 14 | |
Rajeshwari Shinde | 643be9c | 2013-07-04 12:29:17 +0530 | [diff] [blame] | 15 | SRCS := $(COBJS:.o=.c) |
| 16 | OBJS := $(addprefix $(obj),$(COBJS)) |
Chander Kashyap | e21185b | 2011-05-24 20:02:56 +0000 | [diff] [blame] | 17 | |
Chander Kashyap | 5187d8d | 2011-09-20 21:25:03 +0000 | [diff] [blame] | 18 | ALL := $(obj).depend $(LIB) |
| 19 | |
| 20 | ifdef CONFIG_SPL_BUILD |
| 21 | ALL += $(OBJTREE)/tools/mk$(BOARD)spl |
| 22 | endif |
| 23 | |
| 24 | all: $(ALL) |
Chander Kashyap | e21185b | 2011-05-24 20:02:56 +0000 | [diff] [blame] | 25 | |
| 26 | $(LIB): $(OBJS) |
Mike Frysinger | 26ddff2 | 2011-10-18 05:30:17 +0000 | [diff] [blame] | 27 | $(call cmd_link_o_target, $(OBJS)) |
Chander Kashyap | e21185b | 2011-05-24 20:02:56 +0000 | [diff] [blame] | 28 | |
Chander Kashyap | 5187d8d | 2011-09-20 21:25:03 +0000 | [diff] [blame] | 29 | ifdef CONFIG_SPL_BUILD |
| 30 | $(OBJTREE)/tools/mk$(BOARD)spl: tools/mkv310_image.c |
| 31 | $(HOSTCC) tools/mkv310_image.c -o $(OBJTREE)/tools/mk$(BOARD)spl |
| 32 | endif |
| 33 | |
Chander Kashyap | e21185b | 2011-05-24 20:02:56 +0000 | [diff] [blame] | 34 | ######################################################################### |
| 35 | |
| 36 | # defines $(obj).depend target |
| 37 | include $(SRCTREE)/rules.mk |
| 38 | |
| 39 | sinclude $(obj).depend |
| 40 | |
| 41 | ######################################################################### |